/*! jQuery v3.5.1 | (c) JS Foundation and other contributors | jquery.org/license */
!function(e,t){"use strict";"object"==typeof module&&"object"==typeof module.exports?module.exports=e.document?t(e,!0):function(e){if(!e.document)throw new Error("jQuery requires a window with a document");return t(e)}:t(e)}("undefined"!=typeof window?window:this,function(C,e){"use strict";var t=[],r=Object.getPrototypeOf,s=t.slice,g=t.flat?function(e){return t.flat.call(e)}:function(e){return t.concat.apply([],e)},u=t.push,i=t.indexOf,n={},o=n.toString,v=n.hasOwnProperty,a=v.toString,l=a.call(Object),y={},m=function(e){return"function"==typeof e&&"number"!=typeof e.nodeType},x=function(e){return null!=e&&e===e.window},E=C.document,c={type:!0,src:!0,nonce:!0,noModule:!0};function b(e,t,n){var r,i,o=(n=n||E).createElement("script");if(o.text=e,t)for(r in c)(i=t[r]||t.getAttribute&&t.getAttribute(r))&&o.setAttribute(r,i);n.head.appendChild(o).parentNode.removeChild(o)}function w(e){return null==e?e+"":"object"==typeof e||"function"==typeof e?n[o.call(e)]||"object":typeof e}var f="3.5.1",S=function(e,t){return new S.fn.init(e,t)};function p(e){var t=!!e&&"length"in e&&e.length,n=w(e);return!m(e)&&!x(e)&&("array"===n||0===t||"number"==typeof t&&0<t&&t-1 in e)}S.fn=S.prototype={jquery:f,constructor:S,length:0,toArray:function(){return s.call(this)},get:function(e){return null==e?s.call(this):e<0?this[e+this.length]:this[e]},pushStack:function(e){var t=S.merge(this.constructor(),e);return t.prevObject=this,t},each:function(e){return S.each(this,e)},map:function(n){return this.pushStack(S.map(this,function(e,t){return n.call(e,t,e)}))},slice:function(){return this.pushStack(s.apply(this,arguments))},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},even:function(){return this.pushStack(S.grep(this,function(e,t){return(t+1)%2}))},odd:function(){return this.pushStack(S.grep(this,function(e,t){return t%2}))},eq:function(e){var t=this.length,n=+e+(e<0?t:0);return this.pushStack(0<=n&&n<t?[this[n]]:[])},end:function(){return this.prevObject||this.constructor()},push:u,sort:t.sort,splice:t.splice},S.extend=S.fn.extend=function(){var e,t,n,r,i,o,a=arguments[0]||{},s=1,u=arguments.length,l=!1;for("boolean"==typeof a&&(l=a,a=arguments[s]||{},s++),"object"==typeof a||m(a)||(a={}),s===u&&(a=this,s--);s<u;s++)if(null!=(e=arguments[s]))for(t in e)r=e[t],"__proto__"!==t&&a!==r&&(l&&r&&(S.isPlainObject(r)||(i=Array.isArray(r)))?(n=a[t],o=i&&!Array.isArray(n)?[]:i||S.isPlainObject(n)?n:{},i=!1,a[t]=S.extend(l,o,r)):void 0!==r&&(a[t]=r));return a},S.extend({expando:"jQuery"+(f+Math.random()).replace(/\D/g,""),isReady:!0,error:function(e){throw new Error(e)},noop:function(){},isPlainObject:function(e){var t,n;return!(!e||"[object Object]"!==o.call(e))&&(!(t=r(e))||"function"==typeof(n=v.call(t,"constructor")&&t.constructor)&&a.call(n)===l)},isEmptyObject:function(e){var t;for(t in e)return!1;return!0},globalEval:function(e,t,n){b(e,{nonce:t&&t.nonce},n)},each:function(e,t){var n,r=0;if(p(e)){for(n=e.length;r<n;r++)if(!1===t.call(e[r],r,e[r]))break}else for(r in e)if(!1===t.call(e[r],r,e[r]))break;return e},makeArray:function(e,t){var n=t||[];return null!=e&&(p(Object(e))?S.merge(n,"string"==typeof e?[e]:e):u.call(n,e)),n},inArray:function(e,t,n){return null==t?-1:i.call(t,e,n)},merge:function(e,t){for(var n=+t.length,r=0,i=e.length;r<n;r++)e[i++]=t[r];return e.length=i,e},grep:function(e,t,n){for(var r=[],i=0,o=e.length,a=!n;i<o;i++)!t(e[i],i)!==a&&r.push(e[i]);return r},map:function(e,t,n){var r,i,o=0,a=[];if(p(e))for(r=e.length;o<r;o++)null!=(i=t(e[o],o,n))&&a.push(i);else for(o in e)null!=(i=t(e[o],o,n))&&a.push(i);return g(a)},guid:1,support:y}),"function"==typeof Symbol&&(S.fn[Symbol.iterator]=t[Symbol.iterator]),S.each("Boolean Number String Function Array Date RegExp Object Error Symbol".split(" "),function(e,t){n["[object "+t+"]"]=t.toLowerCase()});var d=function(n){var e,d,b,o,i,h,f,g,w,u,l,T,C,a,E,v,s,c,y,S="sizzle"+1*new Date,p=n.document,k=0,r=0,m=ue(),x=ue(),A=ue(),N=ue(),D=function(e,t){return e===t&&(l=!0),0},j={}.hasOwnProperty,t=[],q=t.pop,L=t.push,H=t.push,O=t.slice,P=function(e,t){for(var n=0,r=e.length;n<r;n++)if(e[n]===t)return n;return-1},R="checked|selected|async|autofocus|autoplay|controls|defer|disabled|hidden|ismap|loop|multiple|open|readonly|required|scoped",M="[\\x20\\t\\r\\n\\f]",I="(?:\\\\[\\da-fA-F]{1,6}"+M+"?|\\\\[^\\r\\n\\f]|[\\w-]|[^\0-\\x7f])+",W="\\["+M+"*("+I+")(?:"+M+"*([*^$|!~]?=)"+M+"*(?:'((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\"|("+I+"))|)"+M+"*\\]",F=":("+I+")(?:\\((('((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\")|((?:\\\\.|[^\\\\()[\\]]|"+W+")*)|.*)\\)|)",B=new RegExp(M+"+","g"),$=new RegExp("^"+M+"+|((?:^|[^\\\\])(?:\\\\.)*)"+M+"+$","g"),_=new RegExp("^"+M+"*,"+M+"*"),z=new RegExp("^"+M+"*([>+~]|"+M+")"+M+"*"),U=new RegExp(M+"|>"),X=new RegExp(F),V=new RegExp("^"+I+"$"),G={ID:new RegExp("^#("+I+")"),CLASS:new RegExp("^\\.("+I+")"),TAG:new RegExp("^("+I+"|[*])"),ATTR:new RegExp("^"+W),PSEUDO:new RegExp("^"+F),CHILD:new RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\("+M+"*(even|odd|(([+-]|)(\\d*)n|)"+M+"*(?:([+-]|)"+M+"*(\\d+)|))"+M+"*\\)|)","i"),bool:new RegExp("^(?:"+R+")$","i"),needsContext:new RegExp("^"+M+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+M+"*((?:-\\d)?\\d*)"+M+"*\\)|)(?=[^-]|$)","i")},Y=/HTML$/i,Q=/^(?:input|select|textarea|button)$/i,J=/^h\d$/i,K=/^[^{]+\{\s*\[native \w/,Z=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,ee=/[+~]/,te=new RegExp("\\\\[\\da-fA-F]{1,6}"+M+"?|\\\\([^\\r\\n\\f])","g"),ne=function(e,t){var n="0x"+e.slice(1)-65536;return t||(n<0?String.fromCharCode(n+65536):String.fromCharCode(n>>10|55296,1023&n|56320))},re=/([\0-\x1f\x7f]|^-?\d)|^-$|[^\0-\x1f\x7f-\uFFFF\w-]/g,ie=function(e,t){return t?"\0"===e?"\ufffd":e.slice(0,-1)+"\\"+e.charCodeAt(e.length-1).toString(16)+" ":"\\"+e},oe=function(){T()},ae=be(function(e){return!0===e.disabled&&"fieldset"===e.nodeName.toLowerCase()},{dir:"parentNode",next:"legend"});try{H.apply(t=O.call(p.childNodes),p.childNodes),t[p.childNodes.length].nodeType}catch(e){H={apply:t.length?function(e,t){L.apply(e,O.call(t))}:function(e,t){var n=e.length,r=0;while(e[n++]=t[r++]);e.length=n-1}}}function se(t,e,n,r){var i,o,a,s,u,l,c,f=e&&e.ownerDocument,p=e?e.nodeType:9;if(n=n||[],"string"!=typeof t||!t||1!==p&&9!==p&&11!==p)return n;if(!r&&(T(e),e=e||C,E)){if(11!==p&&(u=Z.exec(t)))if(i=u[1]){if(9===p){if(!(a=e.getElementById(i)))return n;if(a.id===i)return n.push(a),n}else if(f&&(a=f.getElementById(i))&&y(e,a)&&a.id===i)return n.push(a),n}else{if(u[2])return H.apply(n,e.getElementsByTagName(t)),n;if((i=u[3])&&d.getElementsByClassName&&e.getElementsByClassName)return H.apply(n,e.getElementsByClassName(i)),n}if(d.qsa&&!N[t+" "]&&(!v||!v.test(t))&&(1!==p||"object"!==e.nodeName.toLowerCase())){if(c=t,f=e,1===p&&(U.test(t)||z.test(t))){(f=ee.test(t)&&ye(e.parentNode)||e)===e&&d.scope||((s=e.getAttribute("id"))?s=s.replace(re,ie):e.setAttribute("id",s=S)),o=(l=h(t)).length;while(o--)l[o]=(s?"#"+s:":scope")+" "+xe(l[o]);c=l.join(",")}try{return H.apply(n,f.querySelectorAll(c)),n}catch(e){N(t,!0)}finally{s===S&&e.removeAttribute("id")}}}return g(t.replace($,"$1"),e,n,r)}function ue(){var r=[];return function e(t,n){return r.push(t+" ")>b.cacheLength&&delete e[r.shift()],e[t+" "]=n}}function le(e){return e[S]=!0,e}function ce(e){var t=C.createElement("fieldset");try{return!!e(t)}catch(e){return!1}finally{t.parentNode&&t.parentNode.removeChild(t),t=null}}function fe(e,t){var n=e.split("|"),r=n.length;while(r--)b.attrHandle[n[r]]=t}function pe(e,t){var n=t&&e,r=n&&1===e.nodeType&&1===t.nodeType&&e.sourceIndex-t.sourceIndex;if(r)return r;if(n)while(n=n.nextSibling)if(n===t)return-1;return e?1:-1}function de(t){return function(e){return"input"===e.nodeName.toLowerCase()&&e.type===t}}function he(n){return function(e){var t=e.nodeName.toLowerCase();return("input"===t||"button"===t)&&e.type===n}}function ge(t){return function(e){return"form"in e?e.parentNode&&!1===e.disabled?"label"in e?"label"in e.parentNode?e.parentNode.disabled===t:e.disabled===t:e.isDisabled===t||e.isDisabled!==!t&&ae(e)===t:e.disabled===t:"label"in e&&e.disabled===t}}function ve(a){return le(function(o){return o=+o,le(function(e,t){var n,r=a([],e.length,o),i=r.length;while(i--)e[n=r[i]]&&(e[n]=!(t[n]=e[n]))})})}function ye(e){return e&&"undefined"!=typeof e.getElementsByTagName&&e}for(e in d=se.support={},i=se.isXML=function(e){var t=e.namespaceURI,n=(e.ownerDocument||e).documentElement;return!Y.test(t||n&&n.nodeName||"HTML")},T=se.setDocument=function(e){var t,n,r=e?e.ownerDocument||e:p;return r!=C&&9===r.nodeType&&r.documentElement&&(a=(C=r).documentElement,E=!i(C),p!=C&&(n=C.defaultView)&&n.top!==n&&(n.addEventListener?n.addEventListener("unload",oe,!1):n.attachEvent&&n.attachEvent("onunload",oe)),d.scope=ce(function(e){return a.appendChild(e).appendChild(C.createElement("div")),"undefined"!=typeof e.querySelectorAll&&!e.querySelectorAll(":scope fieldset div").length}),d.attributes=ce(function(e){return e.className="i",!e.getAttribute("className")}),d.getElementsByTagName=ce(function(e){return e.appendChild(C.createComment("")),!e.getElementsByTagName("*").length}),d.getElementsByClassName=K.test(C.getElementsByClassName),d.getById=ce(function(e){return a.appendChild(e).id=S,!C.getElementsByName||!C.getElementsByName(S).length}),d.getById?(b.filter.ID=function(e){var t=e.replace(te,ne);return function(e){return e.getAttribute("id")===t}},b.find.ID=function(e,t){if("undefined"!=typeof t.getElementById&&E){var n=t.getElementById(e);return n?[n]:[]}}):(b.filter.ID=function(e){var n=e.replace(te,ne);return function(e){var t="undefined"!=typeof e.getAttributeNode&&e.getAttributeNode("id");return t&&t.value===n}},b.find.ID=function(e,t){if("undefined"!=typeof t.getElementById&&E){var n,r,i,o=t.getElementById(e);if(o){if((n=o.getAttributeNode("id"))&&n.value===e)return[o];i=t.getElementsByName(e),r=0;while(o=i[r++])if((n=o.getAttributeNode("id"))&&n.value===e)return[o]}return[]}}),b.find.TAG=d.getElementsByTagName?function(e,t){return"undefined"!=typeof t.getElementsByTagName?t.getElementsByTagName(e):d.qsa?t.querySelectorAll(e):void 0}:function(e,t){var n,r=[],i=0,o=t.getElementsByTagName(e);if("*"===e){while(n=o[i++])1===n.nodeType&&r.push(n);return r}return o},b.find.CLASS=d.getElementsByClassName&&function(e,t){if("undefined"!=typeof t.getElementsByClassName&&E)return t.getElementsByClassName(e)},s=[],v=[],(d.qsa=K.test(C.querySelectorAll))&&(ce(function(e){var t;a.appendChild(e).innerHTML="<a id='"+S+"'></a><select id='"+S+"-\r\\' msallowcapture=''><option selected=''></option></select>",e.querySelectorAll("[msallowcapture^='']").length&&v.push("[*^$]="+M+"*(?:''|\"\")"),e.querySelectorAll("[selected]").length||v.push("\\["+M+"*(?:value|"+R+")"),e.querySelectorAll("[id~="+S+"-]").length||v.push("~="),(t=C.createElement("input")).setAttribute("name",""),e.appendChild(t),e.querySelectorAll("[name='']").length||v.push("\\["+M+"*name"+M+"*="+M+"*(?:''|\"\")"),e.querySelectorAll(":checked").length||v.push(":checked"),e.querySelectorAll("a#"+S+"+*").length||v.push(".#.+[+~]"),e.querySelectorAll("\\\f"),v.push("[\\r\\n\\f]")}),ce(function(e){e.innerHTML="<a href='' disabled='disabled'></a><select disabled='disabled'><option/></select>";var t=C.createElement("input");t.setAttribute("type","hidden"),e.appendChild(t).setAttribute("name","D"),e.querySelectorAll("[name=d]").length&&v.push("name"+M+"*[*^$|!~]?="),2!==e.querySelectorAll(":enabled").length&&v.push(":enabled",":disabled"),a.appendChild(e).disabled=!0,2!==e.querySelectorAll(":disabled").length&&v.push(":enabled",":disabled"),e.querySelectorAll("*,:x"),v.push(",.*:")})),(d.matchesSelector=K.test(c=a.matches||a.webkitMatchesSelector||a.mozMatchesSelector||a.oMatchesSelector||a.msMatchesSelector))&&ce(function(e){d.disconnectedMatch=c.call(e,"*"),c.call(e,"[s!='']:x"),s.push("!=",F)}),v=v.length&&new RegExp(v.join("|")),s=s.length&&new RegExp(s.join("|")),t=K.test(a.compareDocumentPosition),y=t||K.test(a.contains)?function(e,t){var n=9===e.nodeType?e.documentElement:e,r=t&&t.parentNode;return e===r||!(!r||1!==r.nodeType||!(n.contains?n.contains(r):e.compareDocumentPosition&&16&e.compareDocumentPosition(r)))}:function(e,t){if(t)while(t=t.parentNode)if(t===e)return!0;return!1},D=t?function(e,t){if(e===t)return l=!0,0;var n=!e.compareDocumentPosition-!t.compareDocumentPosition;return n||(1&(n=(e.ownerDocument||e)==(t.ownerDocument||t)?e.compareDocumentPosition(t):1)||!d.sortDetached&&t.compareDocumentPosition(e)===n?e==C||e.ownerDocument==p&&y(p,e)?-1:t==C||t.ownerDocument==p&&y(p,t)?1:u?P(u,e)-P(u,t):0:4&n?-1:1)}:function(e,t){if(e===t)return l=!0,0;var n,r=0,i=e.parentNode,o=t.parentNode,a=[e],s=[t];if(!i||!o)return e==C?-1:t==C?1:i?-1:o?1:u?P(u,e)-P(u,t):0;if(i===o)return pe(e,t);n=e;while(n=n.parentNode)a.unshift(n);n=t;while(n=n.parentNode)s.unshift(n);while(a[r]===s[r])r++;return r?pe(a[r],s[r]):a[r]==p?-1:s[r]==p?1:0}),C},se.matches=function(e,t){return se(e,null,null,t)},se.matchesSelector=function(e,t){if(T(e),d.matchesSelector&&E&&!N[t+" "]&&(!s||!s.test(t))&&(!v||!v.test(t)))try{var n=c.call(e,t);if(n||d.disconnectedMatch||e.document&&11!==e.document.nodeType)return n}catch(e){N(t,!0)}return 0<se(t,C,null,[e]).length},se.contains=function(e,t){return(e.ownerDocument||e)!=C&&T(e),y(e,t)},se.attr=function(e,t){(e.ownerDocument||e)!=C&&T(e);var n=b.attrHandle[t.toLowerCase()],r=n&&j.call(b.attrHandle,t.toLowerCase())?n(e,t,!E):void 0;return void 0!==r?r:d.attributes||!E?e.getAttribute(t):(r=e.getAttributeNode(t))&&r.specified?r.value:null},se.escape=function(e){return(e+"").replace(re,ie)},se.error=function(e){throw new Error("Syntax error, unrecognized expression: "+e)},se.uniqueSort=function(e){var t,n=[],r=0,i=0;if(l=!d.detectDuplicates,u=!d.sortStable&&e.slice(0),e.sort(D),l){while(t=e[i++])t===e[i]&&(r=n.push(i));while(r--)e.splice(n[r],1)}return u=null,e},o=se.getText=function(e){var t,n="",r=0,i=e.nodeType;if(i){if(1===i||9===i||11===i){if("string"==typeof e.textContent)return e.textContent;for(e=e.firstChild;e;e=e.nextSibling)n+=o(e)}else if(3===i||4===i)return e.nodeValue}else while(t=e[r++])n+=o(t);return n},(b=se.selectors={cacheLength:50,createPseudo:le,match:G,attrHandle:{},find:{},relative:{">":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(e){return e[1]=e[1].replace(te,ne),e[3]=(e[3]||e[4]||e[5]||"").replace(te,ne),"~="===e[2]&&(e[3]=" "+e[3]+" "),e.slice(0,4)},CHILD:function(e){return e[1]=e[1].toLowerCase(),"nth"===e[1].slice(0,3)?(e[3]||se.error(e[0]),e[4]=+(e[4]?e[5]+(e[6]||1):2*("even"===e[3]||"odd"===e[3])),e[5]=+(e[7]+e[8]||"odd"===e[3])):e[3]&&se.error(e[0]),e},PSEUDO:function(e){var t,n=!e[6]&&e[2];return G.CHILD.test(e[0])?null:(e[3]?e[2]=e[4]||e[5]||"":n&&X.test(n)&&(t=h(n,!0))&&(t=n.indexOf(")",n.length-t)-n.length)&&(e[0]=e[0].slice(0,t),e[2]=n.slice(0,t)),e.slice(0,3))}},filter:{TAG:function(e){var t=e.replace(te,ne).toLowerCase();return"*"===e?function(){return!0}:function(e){return e.nodeName&&e.nodeName.toLowerCase()===t}},CLASS:function(e){var t=m[e+" "];return t||(t=new RegExp("(^|"+M+")"+e+"("+M+"|$)"))&&m(e,function(e){return t.test("string"==typeof e.className&&e.className||"undefined"!=typeof e.getAttribute&&e.getAttribute("class")||"")})},ATTR:function(n,r,i){return function(e){var t=se.attr(e,n);return null==t?"!="===r:!r||(t+="","="===r?t===i:"!="===r?t!==i:"^="===r?i&&0===t.indexOf(i):"*="===r?i&&-1<t.indexOf(i):"$="===r?i&&t.slice(-i.length)===i:"~="===r?-1<(" "+t.replace(B," ")+" ").indexOf(i):"|="===r&&(t===i||t.slice(0,i.length+1)===i+"-"))}},CHILD:function(h,e,t,g,v){var y="nth"!==h.slice(0,3),m="last"!==h.slice(-4),x="of-type"===e;return 1===g&&0===v?function(e){return!!e.parentNode}:function(e,t,n){var r,i,o,a,s,u,l=y!==m?"nextSibling":"previousSibling",c=e.parentNode,f=x&&e.nodeName.toLowerCase(),p=!n&&!x,d=!1;if(c){if(y){while(l){a=e;while(a=a[l])if(x?a.nodeName.toLowerCase()===f:1===a.nodeType)return!1;u=l="only"===h&&!u&&"nextSibling"}return!0}if(u=[m?c.firstChild:c.lastChild],m&&p){d=(s=(r=(i=(o=(a=c)[S]||(a[S]={}))[a.uniqueID]||(o[a.uniqueID]={}))[h]||[])[0]===k&&r[1])&&r[2],a=s&&c.childNodes[s];while(a=++s&&a&&a[l]||(d=s=0)||u.pop())if(1===a.nodeType&&++d&&a===e){i[h]=[k,s,d];break}}else if(p&&(d=s=(r=(i=(o=(a=e)[S]||(a[S]={}))[a.uniqueID]||(o[a.uniqueID]={}))[h]||[])[0]===k&&r[1]),!1===d)while(a=++s&&a&&a[l]||(d=s=0)||u.pop())if((x?a.nodeName.toLowerCase()===f:1===a.nodeType)&&++d&&(p&&((i=(o=a[S]||(a[S]={}))[a.uniqueID]||(o[a.uniqueID]={}))[h]=[k,d]),a===e))break;return(d-=v)===g||d%g==0&&0<=d/g}}},PSEUDO:function(e,o){var t,a=b.pseudos[e]||b.setFilters[e.toLowerCase()]||se.error("unsupported pseudo: "+e);return a[S]?a(o):1<a.length?(t=[e,e,"",o],b.setFilters.hasOwnProperty(e.toLowerCase())?le(function(e,t){var n,r=a(e,o),i=r.length;while(i--)e[n=P(e,r[i])]=!(t[n]=r[i])}):function(e){return a(e,0,t)}):a}},pseudos:{not:le(function(e){var r=[],i=[],s=f(e.replace($,"$1"));return s[S]?le(function(e,t,n,r){var i,o=s(e,null,r,[]),a=e.length;while(a--)(i=o[a])&&(e[a]=!(t[a]=i))}):function(e,t,n){return r[0]=e,s(r,null,n,i),r[0]=null,!i.pop()}}),has:le(function(t){return function(e){return 0<se(t,e).length}}),contains:le(function(t){return t=t.replace(te,ne),function(e){return-1<(e.textContent||o(e)).indexOf(t)}}),lang:le(function(n){return V.test(n||"")||se.error("unsupported lang: "+n),n=n.replace(te,ne).toLowerCase(),function(e){var t;do{if(t=E?e.lang:e.getAttribute("xml:lang")||e.getAttribute("lang"))return(t=t.toLowerCase())===n||0===t.indexOf(n+"-")}while((e=e.parentNode)&&1===e.nodeType);return!1}}),target:function(e){var t=n.location&&n.location.hash;return t&&t.slice(1)===e.id},root:function(e){return e===a},focus:function(e){return e===C.activeElement&&(!C.hasFocus||C.hasFocus())&&!!(e.type||e.href||~e.tabIndex)},enabled:ge(!1),disabled:ge(!0),checked:function(e){var t=e.nodeName.toLowerCase();return"input"===t&&!!e.checked||"option"===t&&!!e.selected},selected:function(e){return e.parentNode&&e.parentNode.selectedIndex,!0===e.selected},empty:function(e){for(e=e.firstChild;e;e=e.nextSibling)if(e.nodeType<6)return!1;return!0},parent:function(e){return!b.pseudos.empty(e)},header:function(e){return J.test(e.nodeName)},input:function(e){return Q.test(e.nodeName)},button:function(e){var t=e.nodeName.toLowerCase();return"input"===t&&"button"===e.type||"button"===t},text:function(e){var t;return"input"===e.nodeName.toLowerCase()&&"text"===e.type&&(null==(t=e.getAttribute("type"))||"text"===t.toLowerCase())},first:ve(function(){return[0]}),last:ve(function(e,t){return[t-1]}),eq:ve(function(e,t,n){return[n<0?n+t:n]}),even:ve(function(e,t){for(var n=0;n<t;n+=2)e.push(n);return e}),odd:ve(function(e,t){for(var n=1;n<t;n+=2)e.push(n);return e}),lt:ve(function(e,t,n){for(var r=n<0?n+t:t<n?t:n;0<=--r;)e.push(r);return e}),gt:ve(function(e,t,n){for(var r=n<0?n+t:n;++r<t;)e.push(r);return e})}}).pseudos.nth=b.pseudos.eq,{radio:!0,checkbox:!0,file:!0,password:!0,image:!0})b.pseudos[e]=de(e);for(e in{submit:!0,reset:!0})b.pseudos[e]=he(e);function me(){}function xe(e){for(var t=0,n=e.length,r="";t<n;t++)r+=e[t].value;return r}function be(s,e,t){var u=e.dir,l=e.next,c=l||u,f=t&&"parentNode"===c,p=r++;return e.first?function(e,t,n){while(e=e[u])if(1===e.nodeType||f)return s(e,t,n);return!1}:function(e,t,n){var r,i,o,a=[k,p];if(n){while(e=e[u])if((1===e.nodeType||f)&&s(e,t,n))return!0}else while(e=e[u])if(1===e.nodeType||f)if(i=(o=e[S]||(e[S]={}))[e.uniqueID]||(o[e.uniqueID]={}),l&&l===e.nodeName.toLowerCase())e=e[u]||e;else{if((r=i[c])&&r[0]===k&&r[1]===p)return a[2]=r[2];if((i[c]=a)[2]=s(e,t,n))return!0}return!1}}function we(i){return 1<i.length?function(e,t,n){var r=i.length;while(r--)if(!i[r](e,t,n))return!1;return!0}:i[0]}function Te(e,t,n,r,i){for(var o,a=[],s=0,u=e.length,l=null!=t;s<u;s++)(o=e[s])&&(n&&!n(o,r,i)||(a.push(o),l&&t.push(s)));return a}function Ce(d,h,g,v,y,e){return v&&!v[S]&&(v=Ce(v)),y&&!y[S]&&(y=Ce(y,e)),le(function(e,t,n,r){var i,o,a,s=[],u=[],l=t.length,c=e||function(e,t,n){for(var r=0,i=t.length;r<i;r++)se(e,t[r],n);return n}(h||"*",n.nodeType?[n]:n,[]),f=!d||!e&&h?c:Te(c,s,d,n,r),p=g?y||(e?d:l||v)?[]:t:f;if(g&&g(f,p,n,r),v){i=Te(p,u),v(i,[],n,r),o=i.length;while(o--)(a=i[o])&&(p[u[o]]=!(f[u[o]]=a))}if(e){if(y||d){if(y){i=[],o=p.length;while(o--)(a=p[o])&&i.push(f[o]=a);y(null,p=[],i,r)}o=p.length;while(o--)(a=p[o])&&-1<(i=y?P(e,a):s[o])&&(e[i]=!(t[i]=a))}}else p=Te(p===t?p.splice(l,p.length):p),y?y(null,t,p,r):H.apply(t,p)})}function Ee(e){for(var i,t,n,r=e.length,o=b.relative[e[0].type],a=o||b.relative[" "],s=o?1:0,u=be(function(e){return e===i},a,!0),l=be(function(e){return-1<P(i,e)},a,!0),c=[function(e,t,n){var r=!o&&(n||t!==w)||((i=t).nodeType?u(e,t,n):l(e,t,n));return i=null,r}];s<r;s++)if(t=b.relative[e[s].type])c=[be(we(c),t)];else{if((t=b.filter[e[s].type].apply(null,e[s].matches))[S]){for(n=++s;n<r;n++)if(b.relative[e[n].type])break;return Ce(1<s&&we(c),1<s&&xe(e.slice(0,s-1).concat({value:" "===e[s-2].type?"*":""})).replace($,"$1"),t,s<n&&Ee(e.slice(s,n)),n<r&&Ee(e=e.slice(n)),n<r&&xe(e))}c.push(t)}return we(c)}return me.prototype=b.filters=b.pseudos,b.setFilters=new me,h=se.tokenize=function(e,t){var n,r,i,o,a,s,u,l=x[e+" "];if(l)return t?0:l.slice(0);a=e,s=[],u=b.preFilter;while(a){for(o in n&&!(r=_.exec(a))||(r&&(a=a.slice(r[0].length)||a),s.push(i=[])),n=!1,(r=z.exec(a))&&(n=r.shift(),i.push({value:n,type:r[0].replace($," ")}),a=a.slice(n.length)),b.filter)!(r=G[o].exec(a))||u[o]&&!(r=u[o](r))||(n=r.shift(),i.push({value:n,type:o,matches:r}),a=a.slice(n.length));if(!n)break}return t?a.length:a?se.error(e):x(e,s).slice(0)},f=se.compile=function(e,t){var n,v,y,m,x,r,i=[],o=[],a=A[e+" "];if(!a){t||(t=h(e)),n=t.length;while(n--)(a=Ee(t[n]))[S]?i.push(a):o.push(a);(a=A(e,(v=o,m=0<(y=i).length,x=0<v.length,r=function(e,t,n,r,i){var o,a,s,u=0,l="0",c=e&&[],f=[],p=w,d=e||x&&b.find.TAG("*",i),h=k+=null==p?1:Math.random()||.1,g=d.length;for(i&&(w=t==C||t||i);l!==g&&null!=(o=d[l]);l++){if(x&&o){a=0,t||o.ownerDocument==C||(T(o),n=!E);while(s=v[a++])if(s(o,t||C,n)){r.push(o);break}i&&(k=h)}m&&((o=!s&&o)&&u--,e&&c.push(o))}if(u+=l,m&&l!==u){a=0;while(s=y[a++])s(c,f,t,n);if(e){if(0<u)while(l--)c[l]||f[l]||(f[l]=q.call(r));f=Te(f)}H.apply(r,f),i&&!e&&0<f.length&&1<u+y.length&&se.uniqueSort(r)}return i&&(k=h,w=p),c},m?le(r):r))).selector=e}return a},g=se.select=function(e,t,n,r){var i,o,a,s,u,l="function"==typeof e&&e,c=!r&&h(e=l.selector||e);if(n=n||[],1===c.length){if(2<(o=c[0]=c[0].slice(0)).length&&"ID"===(a=o[0]).type&&9===t.nodeType&&E&&b.relative[o[1].type]){if(!(t=(b.find.ID(a.matches[0].replace(te,ne),t)||[])[0]))return n;l&&(t=t.parentNode),e=e.slice(o.shift().value.length)}i=G.needsContext.test(e)?0:o.length;while(i--){if(a=o[i],b.relative[s=a.type])break;if((u=b.find[s])&&(r=u(a.matches[0].replace(te,ne),ee.test(o[0].type)&&ye(t.parentNode)||t))){if(o.splice(i,1),!(e=r.length&&xe(o)))return H.apply(n,r),n;break}}}return(l||f(e,c))(r,t,!E,n,!t||ee.test(e)&&ye(t.parentNode)||t),n},d.sortStable=S.split("").sort(D).join("")===S,d.detectDuplicates=!!l,T(),d.sortDetached=ce(function(e){return 1&e.compareDocumentPosition(C.createElement("fieldset"))}),ce(function(e){return e.innerHTML="<a href='#'></a>","#"===e.firstChild.getAttribute("href")})||fe("type|href|height|width",function(e,t,n){if(!n)return e.getAttribute(t,"type"===t.toLowerCase()?1:2)}),d.attributes&&ce(function(e){return e.innerHTML="<input/>",e.firstChild.setAttribute("value",""),""===e.firstChild.getAttribute("value")})||fe("value",function(e,t,n){if(!n&&"input"===e.nodeName.toLowerCase())return e.defaultValue}),ce(function(e){return null==e.getAttribute("disabled")})||fe(R,function(e,t,n){var r;if(!n)return!0===e[t]?t.toLowerCase():(r=e.getAttributeNode(t))&&r.specified?r.value:null}),se}(C);S.find=d,S.expr=d.selectors,S.expr[":"]=S.expr.pseudos,S.uniqueSort=S.unique=d.uniqueSort,S.text=d.getText,S.isXMLDoc=d.isXML,S.contains=d.contains,S.escapeSelector=d.escape;var h=function(e,t,n){var r=[],i=void 0!==n;while((e=e[t])&&9!==e.nodeType)if(1===e.nodeType){if(i&&S(e).is(n))break;r.push(e)}return r},T=function(e,t){for(var n=[];e;e=e.nextSibling)1===e.nodeType&&e!==t&&n.push(e);return n},k=S.expr.match.needsContext;function A(e,t){return e.nodeName&&e.nodeName.toLowerCase()===t.toLowerCase()}var N=/^<([a-z][^\/\0>:\x20\t\r\n\f]*)[\x20\t\r\n\f]*\/?>(?:<\/\1>|)$/i;function D(e,n,r){return m(n)?S.grep(e,function(e,t){return!!n.call(e,t,e)!==r}):n.nodeType?S.grep(e,function(e){return e===n!==r}):"string"!=typeof n?S.grep(e,function(e){return-1<i.call(n,e)!==r}):S.filter(n,e,r)}S.filter=function(e,t,n){var r=t[0];return n&&(e=":not("+e+")"),1===t.length&&1===r.nodeType?S.find.matchesSelector(r,e)?[r]:[]:S.find.matches(e,S.grep(t,function(e){return 1===e.nodeType}))},S.fn.extend({find:function(e){var t,n,r=this.length,i=this;if("string"!=typeof e)return this.pushStack(S(e).filter(function(){for(t=0;t<r;t++)if(S.contains(i[t],this))return!0}));for(n=this.pushStack([]),t=0;t<r;t++)S.find(e,i[t],n);return 1<r?S.uniqueSort(n):n},filter:function(e){return this.pushStack(D(this,e||[],!1))},not:function(e){return this.pushStack(D(this,e||[],!0))},is:function(e){return!!D(this,"string"==typeof e&&k.test(e)?S(e):e||[],!1).length}});var j,q=/^(?:\s*(<[\w\W]+>)[^>]*|#([\w-]+))$/;(S.fn.init=function(e,t,n){var r,i;if(!e)return this;if(n=n||j,"string"==typeof e){if(!(r="<"===e[0]&&">"===e[e.length-1]&&3<=e.length?[null,e,null]:q.exec(e))||!r[1]&&t)return!t||t.jquery?(t||n).find(e):this.constructor(t).find(e);if(r[1]){if(t=t instanceof S?t[0]:t,S.merge(this,S.parseHTML(r[1],t&&t.nodeType?t.ownerDocument||t:E,!0)),N.test(r[1])&&S.isPlainObject(t))for(r in t)m(this[r])?this[r](t[r]):this.attr(r,t[r]);return this}return(i=E.getElementById(r[2]))&&(this[0]=i,this.length=1),this}return e.nodeType?(this[0]=e,this.length=1,this):m(e)?void 0!==n.ready?n.ready(e):e(S):S.makeArray(e,this)}).prototype=S.fn,j=S(E);var L=/^(?:parents|prev(?:Until|All))/,H={children:!0,contents:!0,next:!0,prev:!0};function O(e,t){while((e=e[t])&&1!==e.nodeType);return e}S.fn.extend({has:function(e){var t=S(e,this),n=t.length;return this.filter(function(){for(var e=0;e<n;e++)if(S.contains(this,t[e]))return!0})},closest:function(e,t){var n,r=0,i=this.length,o=[],a="string"!=typeof e&&S(e);if(!k.test(e))for(;r<i;r++)for(n=this[r];n&&n!==t;n=n.parentNode)if(n.nodeType<11&&(a?-1<a.index(n):1===n.nodeType&&S.find.matchesSelector(n,e))){o.push(n);break}return this.pushStack(1<o.length?S.uniqueSort(o):o)},index:function(e){return e?"string"==typeof e?i.call(S(e),this[0]):i.call(this,e.jquery?e[0]:e):this[0]&&this[0].parentNode?this.first().prevAll().length:-1},add:function(e,t){return this.pushStack(S.uniqueSort(S.merge(this.get(),S(e,t))))},addBack:function(e){return this.add(null==e?this.prevObject:this.prevObject.filter(e))}}),S.each({parent:function(e){var t=e.parentNode;return t&&11!==t.nodeType?t:null},parents:function(e){return h(e,"parentNode")},parentsUntil:function(e,t,n){return h(e,"parentNode",n)},next:function(e){return O(e,"nextSibling")},prev:function(e){return O(e,"previousSibling")},nextAll:function(e){return h(e,"nextSibling")},prevAll:function(e){return h(e,"previousSibling")},nextUntil:function(e,t,n){return h(e,"nextSibling",n)},prevUntil:function(e,t,n){return h(e,"previousSibling",n)},siblings:function(e){return T((e.parentNode||{}).firstChild,e)},children:function(e){return T(e.firstChild)},contents:function(e){return null!=e.contentDocument&&r(e.contentDocument)?e.contentDocument:(A(e,"template")&&(e=e.content||e),S.merge([],e.childNodes))}},function(r,i){S.fn[r]=function(e,t){var n=S.map(this,i,e);return"Until"!==r.slice(-5)&&(t=e),t&&"string"==typeof t&&(n=S.filter(t,n)),1<this.length&&(H[r]||S.uniqueSort(n),L.test(r)&&n.reverse()),this.pushStack(n)}});var P=/[^\x20\t\r\n\f]+/g;function R(e){return e}function M(e){throw e}function I(e,t,n,r){var i;try{e&&m(i=e.promise)?i.call(e).done(t).fail(n):e&&m(i=e.then)?i.call(e,t,n):t.apply(void 0,[e].slice(r))}catch(e){n.apply(void 0,[e])}}S.Callbacks=function(r){var e,n;r="string"==typeof r?(e=r,n={},S.each(e.match(P)||[],function(e,t){n[t]=!0}),n):S.extend({},r);var i,t,o,a,s=[],u=[],l=-1,c=function(){for(a=a||r.once,o=i=!0;u.length;l=-1){t=u.shift();while(++l<s.length)!1===s[l].apply(t[0],t[1])&&r.stopOnFalse&&(l=s.length,t=!1)}r.memory||(t=!1),i=!1,a&&(s=t?[]:"")},f={add:function(){return s&&(t&&!i&&(l=s.length-1,u.push(t)),function n(e){S.each(e,function(e,t){m(t)?r.unique&&f.has(t)||s.push(t):t&&t.length&&"string"!==w(t)&&n(t)})}(arguments),t&&!i&&c()),this},remove:function(){return S.each(arguments,function(e,t){var n;while(-1<(n=S.inArray(t,s,n)))s.splice(n,1),n<=l&&l--}),this},has:function(e){return e?-1<S.inArray(e,s):0<s.length},empty:function(){return s&&(s=[]),this},disable:function(){return a=u=[],s=t="",this},disabled:function(){return!s},lock:function(){return a=u=[],t||i||(s=t=""),this},locked:function(){return!!a},fireWith:function(e,t){return a||(t=[e,(t=t||[]).slice?t.slice():t],u.push(t),i||c()),this},fire:function(){return f.fireWith(this,arguments),this},fired:function(){return!!o}};return f},S.extend({Deferred:function(e){var o=[["notify","progress",S.Callbacks("memory"),S.Callbacks("memory"),2],["resolve","done",S.Callbacks("once memory"),S.Callbacks("once memory"),0,"resolved"],["reject","fail",S.Callbacks("once memory"),S.Callbacks("once memory"),1,"rejected"]],i="pending",a={state:function(){return i},always:function(){return s.done(arguments).fail(arguments),this},"catch":function(e){return a.then(null,e)},pipe:function(){var i=arguments;return S.Deferred(function(r){S.each(o,function(e,t){var n=m(i[t[4]])&&i[t[4]];s[t[1]](function(){var e=n&&n.apply(this,arguments);e&&m(e.promise)?e.promise().progress(r.notify).done(r.resolve).fail(r.reject):r[t[0]+"With"](this,n?[e]:arguments)})}),i=null}).promise()},then:function(t,n,r){var u=0;function l(i,o,a,s){return function(){var n=this,r=arguments,e=function(){var e,t;if(!(i<u)){if((e=a.apply(n,r))===o.promise())throw new TypeError("Thenable self-resolution");t=e&&("object"==typeof e||"function"==typeof e)&&e.then,m(t)?s?t.call(e,l(u,o,R,s),l(u,o,M,s)):(u++,t.call(e,l(u,o,R,s),l(u,o,M,s),l(u,o,R,o.notifyWith))):(a!==R&&(n=void 0,r=[e]),(s||o.resolveWith)(n,r))}},t=s?e:function(){try{e()}catch(e){S.Deferred.exceptionHook&&S.Deferred.exceptionHook(e,t.stackTrace),u<=i+1&&(a!==M&&(n=void 0,r=[e]),o.rejectWith(n,r))}};i?t():(S.Deferred.getStackHook&&(t.stackTrace=S.Deferred.getStackHook()),C.setTimeout(t))}}return S.Deferred(function(e){o[0][3].add(l(0,e,m(r)?r:R,e.notifyWith)),o[1][3].add(l(0,e,m(t)?t:R)),o[2][3].add(l(0,e,m(n)?n:M))}).promise()},promise:function(e){return null!=e?S.extend(e,a):a}},s={};return S.each(o,function(e,t){var n=t[2],r=t[5];a[t[1]]=n.add,r&&n.add(function(){i=r},o[3-e][2].disable,o[3-e][3].disable,o[0][2].lock,o[0][3].lock),n.add(t[3].fire),s[t[0]]=function(){return s[t[0]+"With"](this===s?void 0:this,arguments),this},s[t[0]+"With"]=n.fireWith}),a.promise(s),e&&e.call(s,s),s},when:function(e){var n=arguments.length,t=n,r=Array(t),i=s.call(arguments),o=S.Deferred(),a=function(t){return function(e){r[t]=this,i[t]=1<arguments.length?s.call(arguments):e,--n||o.resolveWith(r,i)}};if(n<=1&&(I(e,o.done(a(t)).resolve,o.reject,!n),"pending"===o.state()||m(i[t]&&i[t].then)))return o.then();while(t--)I(i[t],a(t),o.reject);return o.promise()}});var W=/^(Eval|Internal|Range|Reference|Syntax|Type|URI)Error$/;S.Deferred.exceptionHook=function(e,t){C.console&&C.console.warn&&e&&W.test(e.name)&&C.console.warn("jQuery.Deferred exception: "+e.message,e.stack,t)},S.readyException=function(e){C.setTimeout(function(){throw e})};var F=S.Deferred();function B(){E.removeEventListener("DOMContentLoaded",B),C.removeEventListener("load",B),S.ready()}S.fn.ready=function(e){return F.then(e)["catch"](function(e){S.readyException(e)}),this},S.extend({isReady:!1,readyWait:1,ready:function(e){(!0===e?--S.readyWait:S.isReady)||(S.isReady=!0)!==e&&0<--S.readyWait||F.resolveWith(E,[S])}}),S.ready.then=F.then,"complete"===E.readyState||"loading"!==E.readyState&&!E.documentElement.doScroll?C.setTimeout(S.ready):(E.addEventListener("DOMContentLoaded",B),C.addEventListener("load",B));var $=function(e,t,n,r,i,o,a){var s=0,u=e.length,l=null==n;if("object"===w(n))for(s in i=!0,n)$(e,t,s,n[s],!0,o,a);else if(void 0!==r&&(i=!0,m(r)||(a=!0),l&&(a?(t.call(e,r),t=null):(l=t,t=function(e,t,n){return l.call(S(e),n)})),t))for(;s<u;s++)t(e[s],n,a?r:r.call(e[s],s,t(e[s],n)));return i?e:l?t.call(e):u?t(e[0],n):o},_=/^-ms-/,z=/-([a-z])/g;function U(e,t){return t.toUpperCase()}function X(e){return e.replace(_,"ms-").replace(z,U)}var V=function(e){return 1===e.nodeType||9===e.nodeType||!+e.nodeType};function G(){this.expando=S.expando+G.uid++}G.uid=1,G.prototype={cache:function(e){var t=e[this.expando];return t||(t={},V(e)&&(e.nodeType?e[this.expando]=t:Object.defineProperty(e,this.expando,{value:t,configurable:!0}))),t},set:function(e,t,n){var r,i=this.cache(e);if("string"==typeof t)i[X(t)]=n;else for(r in t)i[X(r)]=t[r];return i},get:function(e,t){return void 0===t?this.cache(e):e[this.expando]&&e[this.expando][X(t)]},access:function(e,t,n){return void 0===t||t&&"string"==typeof t&&void 0===n?this.get(e,t):(this.set(e,t,n),void 0!==n?n:t)},remove:function(e,t){var n,r=e[this.expando];if(void 0!==r){if(void 0!==t){n=(t=Array.isArray(t)?t.map(X):(t=X(t))in r?[t]:t.match(P)||[]).length;while(n--)delete r[t[n]]}(void 0===t||S.isEmptyObject(r))&&(e.nodeType?e[this.expando]=void 0:delete e[this.expando])}},hasData:function(e){var t=e[this.expando];return void 0!==t&&!S.isEmptyObject(t)}};var Y=new G,Q=new G,J=/^(?:\{[\w\W]*\}|\[[\w\W]*\])$/,K=/[A-Z]/g;function Z(e,t,n){var r,i;if(void 0===n&&1===e.nodeType)if(r="data-"+t.replace(K,"-$&").toLowerCase(),"string"==typeof(n=e.getAttribute(r))){try{n="true"===(i=n)||"false"!==i&&("null"===i?null:i===+i+""?+i:J.test(i)?JSON.parse(i):i)}catch(e){}Q.set(e,t,n)}else n=void 0;return n}S.extend({hasData:function(e){return Q.hasData(e)||Y.hasData(e)},data:function(e,t,n){return Q.access(e,t,n)},removeData:function(e,t){Q.remove(e,t)},_data:function(e,t,n){return Y.access(e,t,n)},_removeData:function(e,t){Y.remove(e,t)}}),S.fn.extend({data:function(n,e){var t,r,i,o=this[0],a=o&&o.attributes;if(void 0===n){if(this.length&&(i=Q.get(o),1===o.nodeType&&!Y.get(o,"hasDataAttrs"))){t=a.length;while(t--)a[t]&&0===(r=a[t].name).indexOf("data-")&&(r=X(r.slice(5)),Z(o,r,i[r]));Y.set(o,"hasDataAttrs",!0)}return i}return"object"==typeof n?this.each(function(){Q.set(this,n)}):$(this,function(e){var t;if(o&&void 0===e)return void 0!==(t=Q.get(o,n))?t:void 0!==(t=Z(o,n))?t:void 0;this.each(function(){Q.set(this,n,e)})},null,e,1<arguments.length,null,!0)},removeData:function(e){return this.each(function(){Q.remove(this,e)})}}),S.extend({queue:function(e,t,n){var r;if(e)return t=(t||"fx")+"queue",r=Y.get(e,t),n&&(!r||Array.isArray(n)?r=Y.access(e,t,S.makeArray(n)):r.push(n)),r||[]},dequeue:function(e,t){t=t||"fx";var n=S.queue(e,t),r=n.length,i=n.shift(),o=S._queueHooks(e,t);"inprogress"===i&&(i=n.shift(),r--),i&&("fx"===t&&n.unshift("inprogress"),delete o.stop,i.call(e,function(){S.dequeue(e,t)},o)),!r&&o&&o.empty.fire()},_queueHooks:function(e,t){var n=t+"queueHooks";return Y.get(e,n)||Y.access(e,n,{empty:S.Callbacks("once memory").add(function(){Y.remove(e,[t+"queue",n])})})}}),S.fn.extend({queue:function(t,n){var e=2;return"string"!=typeof t&&(n=t,t="fx",e--),arguments.length<e?S.queue(this[0],t):void 0===n?this:this.each(function(){var e=S.queue(this,t,n);S._queueHooks(this,t),"fx"===t&&"inprogress"!==e[0]&&S.dequeue(this,t)})},dequeue:function(e){return this.each(function(){S.dequeue(this,e)})},clearQueue:function(e){return this.queue(e||"fx",[])},promise:function(e,t){var n,r=1,i=S.Deferred(),o=this,a=this.length,s=function(){--r||i.resolveWith(o,[o])};"string"!=typeof e&&(t=e,e=void 0),e=e||"fx";while(a--)(n=Y.get(o[a],e+"queueHooks"))&&n.empty&&(r++,n.empty.add(s));return s(),i.promise(t)}});var ee=/[+-]?(?:\d*\.|)\d+(?:[eE][+-]?\d+|)/.source,te=new RegExp("^(?:([+-])=|)("+ee+")([a-z%]*)$","i"),ne=["Top","Right","Bottom","Left"],re=E.documentElement,ie=function(e){return S.contains(e.ownerDocument,e)},oe={composed:!0};re.getRootNode&&(ie=function(e){return S.contains(e.ownerDocument,e)||e.getRootNode(oe)===e.ownerDocument});var ae=function(e,t){return"none"===(e=t||e).style.display||""===e.style.display&&ie(e)&&"none"===S.css(e,"display")};function se(e,t,n,r){var i,o,a=20,s=r?function(){return r.cur()}:function(){return S.css(e,t,"")},u=s(),l=n&&n[3]||(S.cssNumber[t]?"":"px"),c=e.nodeType&&(S.cssNumber[t]||"px"!==l&&+u)&&te.exec(S.css(e,t));if(c&&c[3]!==l){u/=2,l=l||c[3],c=+u||1;while(a--)S.style(e,t,c+l),(1-o)*(1-(o=s()/u||.5))<=0&&(a=0),c/=o;c*=2,S.style(e,t,c+l),n=n||[]}return n&&(c=+c||+u||0,i=n[1]?c+(n[1]+1)*n[2]:+n[2],r&&(r.unit=l,r.start=c,r.end=i)),i}var ue={};function le(e,t){for(var n,r,i,o,a,s,u,l=[],c=0,f=e.length;c<f;c++)(r=e[c]).style&&(n=r.style.display,t?("none"===n&&(l[c]=Y.get(r,"display")||null,l[c]||(r.style.display="")),""===r.style.display&&ae(r)&&(l[c]=(u=a=o=void 0,a=(i=r).ownerDocument,s=i.nodeName,(u=ue[s])||(o=a.body.appendChild(a.createElement(s)),u=S.css(o,"display"),o.parentNode.removeChild(o),"none"===u&&(u="block"),ue[s]=u)))):"none"!==n&&(l[c]="none",Y.set(r,"display",n)));for(c=0;c<f;c++)null!=l[c]&&(e[c].style.display=l[c]);return e}S.fn.extend({show:function(){return le(this,!0)},hide:function(){return le(this)},toggle:function(e){return"boolean"==typeof e?e?this.show():this.hide():this.each(function(){ae(this)?S(this).show():S(this).hide()})}});var ce,fe,pe=/^(?:checkbox|radio)$/i,de=/<([a-z][^\/\0>\x20\t\r\n\f]*)/i,he=/^$|^module$|\/(?:java|ecma)script/i;ce=E.createDocumentFragment().appendChild(E.createElement("div")),(fe=E.createElement("input")).setAttribute("type","radio"),fe.setAttribute("checked","checked"),fe.setAttribute("name","t"),ce.appendChild(fe),y.checkClone=ce.cloneNode(!0).cloneNode(!0).lastChild.checked,ce.innerHTML="<textarea>x</textarea>",y.noCloneChecked=!!ce.cloneNode(!0).lastChild.defaultValue,ce.innerHTML="<option></option>",y.option=!!ce.lastChild;var ge={thead:[1,"<table>","</table>"],col:[2,"<table><colgroup>","</colgroup></table>"],tr:[2,"<table><tbody>","</tbody></table>"],td:[3,"<table><tbody><tr>","</tr></tbody></table>"],_default:[0,"",""]};function ve(e,t){var n;return n="undefined"!=typeof e.getElementsByTagName?e.getElementsByTagName(t||"*"):"undefined"!=typeof e.querySelectorAll?e.querySelectorAll(t||"*"):[],void 0===t||t&&A(e,t)?S.merge([e],n):n}function ye(e,t){for(var n=0,r=e.length;n<r;n++)Y.set(e[n],"globalEval",!t||Y.get(t[n],"globalEval"))}ge.tbody=ge.tfoot=ge.colgroup=ge.caption=ge.thead,ge.th=ge.td,y.option||(ge.optgroup=ge.option=[1,"<select multiple='multiple'>","</select>"]);var me=/<|&#?\w+;/;function xe(e,t,n,r,i){for(var o,a,s,u,l,c,f=t.createDocumentFragment(),p=[],d=0,h=e.length;d<h;d++)if((o=e[d])||0===o)if("object"===w(o))S.merge(p,o.nodeType?[o]:o);else if(me.test(o)){a=a||f.appendChild(t.createElement("div")),s=(de.exec(o)||["",""])[1].toLowerCase(),u=ge[s]||ge._default,a.innerHTML=u[1]+S.htmlPrefilter(o)+u[2],c=u[0];while(c--)a=a.lastChild;S.merge(p,a.childNodes),(a=f.firstChild).textContent=""}else p.push(t.createTextNode(o));f.textContent="",d=0;while(o=p[d++])if(r&&-1<S.inArray(o,r))i&&i.push(o);else if(l=ie(o),a=ve(f.appendChild(o),"script"),l&&ye(a),n){c=0;while(o=a[c++])he.test(o.type||"")&&n.push(o)}return f}var be=/^key/,we=/^(?:mouse|pointer|contextmenu|drag|drop)|click/,Te=/^([^.]*)(?:\.(.+)|)/;function Ce(){return!0}function Ee(){return!1}function Se(e,t){return e===function(){try{return E.activeElement}catch(e){}}()==("focus"===t)}function ke(e,t,n,r,i,o){var a,s;if("object"==typeof t){for(s in"string"!=typeof n&&(r=r||n,n=void 0),t)ke(e,s,n,r,t[s],o);return e}if(null==r&&null==i?(i=n,r=n=void 0):null==i&&("string"==typeof n?(i=r,r=void 0):(i=r,r=n,n=void 0)),!1===i)i=Ee;else if(!i)return e;return 1===o&&(a=i,(i=function(e){return S().off(e),a.apply(this,arguments)}).guid=a.guid||(a.guid=S.guid++)),e.each(function(){S.event.add(this,t,i,r,n)})}function Ae(e,i,o){o?(Y.set(e,i,!1),S.event.add(e,i,{namespace:!1,handler:function(e){var t,n,r=Y.get(this,i);if(1&e.isTrigger&&this[i]){if(r.length)(S.event.special[i]||{}).delegateType&&e.stopPropagation();else if(r=s.call(arguments),Y.set(this,i,r),t=o(this,i),this[i](),r!==(n=Y.get(this,i))||t?Y.set(this,i,!1):n={},r!==n)return e.stopImmediatePropagation(),e.preventDefault(),n.value}else r.length&&(Y.set(this,i,{value:S.event.trigger(S.extend(r[0],S.Event.prototype),r.slice(1),this)}),e.stopImmediatePropagation())}})):void 0===Y.get(e,i)&&S.event.add(e,i,Ce)}S.event={global:{},add:function(t,e,n,r,i){var o,a,s,u,l,c,f,p,d,h,g,v=Y.get(t);if(V(t)){n.handler&&(n=(o=n).handler,i=o.selector),i&&S.find.matchesSelector(re,i),n.guid||(n.guid=S.guid++),(u=v.events)||(u=v.events=Object.create(null)),(a=v.handle)||(a=v.handle=function(e){return"undefined"!=typeof S&&S.event.triggered!==e.type?S.event.dispatch.apply(t,arguments):void 0}),l=(e=(e||"").match(P)||[""]).length;while(l--)d=g=(s=Te.exec(e[l])||[])[1],h=(s[2]||"").split(".").sort(),d&&(f=S.event.special[d]||{},d=(i?f.delegateType:f.bindType)||d,f=S.event.special[d]||{},c=S.extend({type:d,origType:g,data:r,handler:n,guid:n.guid,selector:i,needsContext:i&&S.expr.match.needsContext.test(i),namespace:h.join(".")},o),(p=u[d])||((p=u[d]=[]).delegateCount=0,f.setup&&!1!==f.setup.call(t,r,h,a)||t.addEventListener&&t.addEventListener(d,a)),f.add&&(f.add.call(t,c),c.handler.guid||(c.handler.guid=n.guid)),i?p.splice(p.delegateCount++,0,c):p.push(c),S.event.global[d]=!0)}},remove:function(e,t,n,r,i){var o,a,s,u,l,c,f,p,d,h,g,v=Y.hasData(e)&&Y.get(e);if(v&&(u=v.events)){l=(t=(t||"").match(P)||[""]).length;while(l--)if(d=g=(s=Te.exec(t[l])||[])[1],h=(s[2]||"").split(".").sort(),d){f=S.event.special[d]||{},p=u[d=(r?f.delegateType:f.bindType)||d]||[],s=s[2]&&new RegExp("(^|\\.)"+h.join("\\.(?:.*\\.|)")+"(\\.|$)"),a=o=p.length;while(o--)c=p[o],!i&&g!==c.origType||n&&n.guid!==c.guid||s&&!s.test(c.namespace)||r&&r!==c.selector&&("**"!==r||!c.selector)||(p.splice(o,1),c.selector&&p.delegateCount--,f.remove&&f.remove.call(e,c));a&&!p.length&&(f.teardown&&!1!==f.teardown.call(e,h,v.handle)||S.removeEvent(e,d,v.handle),delete u[d])}else for(d in u)S.event.remove(e,d+t[l],n,r,!0);S.isEmptyObject(u)&&Y.remove(e,"handle events")}},dispatch:function(e){var t,n,r,i,o,a,s=new Array(arguments.length),u=S.event.fix(e),l=(Y.get(this,"events")||Object.create(null))[u.type]||[],c=S.event.special[u.type]||{};for(s[0]=u,t=1;t<arguments.length;t++)s[t]=arguments[t];if(u.delegateTarget=this,!c.preDispatch||!1!==c.preDispatch.call(this,u)){a=S.event.handlers.call(this,u,l),t=0;while((i=a[t++])&&!u.isPropagationStopped()){u.currentTarget=i.elem,n=0;while((o=i.handlers[n++])&&!u.isImmediatePropagationStopped())u.rnamespace&&!1!==o.namespace&&!u.rnamespace.test(o.namespace)||(u.handleObj=o,u.data=o.data,void 0!==(r=((S.event.special[o.origType]||{}).handle||o.handler).apply(i.elem,s))&&!1===(u.result=r)&&(u.preventDefault(),u.stopPropagation()))}return c.postDispatch&&c.postDispatch.call(this,u),u.result}},handlers:function(e,t){var n,r,i,o,a,s=[],u=t.delegateCount,l=e.target;if(u&&l.nodeType&&!("click"===e.type&&1<=e.button))for(;l!==this;l=l.parentNode||this)if(1===l.nodeType&&("click"!==e.type||!0!==l.disabled)){for(o=[],a={},n=0;n<u;n++)void 0===a[i=(r=t[n]).selector+" "]&&(a[i]=r.needsContext?-1<S(i,this).index(l):S.find(i,this,null,[l]).length),a[i]&&o.push(r);o.length&&s.push({elem:l,handlers:o})}return l=this,u<t.length&&s.push({elem:l,handlers:t.slice(u)}),s},addProp:function(t,e){Object.defineProperty(S.Event.prototype,t,{enumerable:!0,configurable:!0,get:m(e)?function(){if(this.originalEvent)return e(this.originalEvent)}:function(){if(this.originalEvent)return this.originalEvent[t]},set:function(e){Object.defineProperty(this,t,{enumerable:!0,configurable:!0,writable:!0,value:e})}})},fix:function(e){return e[S.expando]?e:new S.Event(e)},special:{load:{noBubble:!0},click:{setup:function(e){var t=this||e;return pe.test(t.type)&&t.click&&A(t,"input")&&Ae(t,"click",Ce),!1},trigger:function(e){var t=this||e;return pe.test(t.type)&&t.click&&A(t,"input")&&Ae(t,"click"),!0},_default:function(e){var t=e.target;return pe.test(t.type)&&t.click&&A(t,"input")&&Y.get(t,"click")||A(t,"a")}},beforeunload:{postDispatch:function(e){void 0!==e.result&&e.originalEvent&&(e.originalEvent.returnValue=e.result)}}}},S.removeEvent=function(e,t,n){e.removeEventListener&&e.removeEventListener(t,n)},S.Event=function(e,t){if(!(this instanceof S.Event))return new S.Event(e,t);e&&e.type?(this.originalEvent=e,this.type=e.type,this.isDefaultPrevented=e.defaultPrevented||void 0===e.defaultPrevented&&!1===e.returnValue?Ce:Ee,this.target=e.target&&3===e.target.nodeType?e.target.parentNode:e.target,this.currentTarget=e.currentTarget,this.relatedTarget=e.relatedTarget):this.type=e,t&&S.extend(this,t),this.timeStamp=e&&e.timeStamp||Date.now(),this[S.expando]=!0},S.Event.prototype={constructor:S.Event,isDefaultPrevented:Ee,isPropagationStopped:Ee,isImmediatePropagationStopped:Ee,isSimulated:!1,preventDefault:function(){var e=this.originalEvent;this.isDefaultPrevented=Ce,e&&!this.isSimulated&&e.preventDefault()},stopPropagation:function(){var e=this.originalEvent;this.isPropagationStopped=Ce,e&&!this.isSimulated&&e.stopPropagation()},stopImmediatePropagation:function(){var e=this.originalEvent;this.isImmediatePropagationStopped=Ce,e&&!this.isSimulated&&e.stopImmediatePropagation(),this.stopPropagation()}},S.each({altKey:!0,bubbles:!0,cancelable:!0,changedTouches:!0,ctrlKey:!0,detail:!0,eventPhase:!0,metaKey:!0,pageX:!0,pageY:!0,shiftKey:!0,view:!0,"char":!0,code:!0,charCode:!0,key:!0,keyCode:!0,button:!0,buttons:!0,clientX:!0,clientY:!0,offsetX:!0,offsetY:!0,pointerId:!0,pointerType:!0,screenX:!0,screenY:!0,targetTouches:!0,toElement:!0,touches:!0,which:function(e){var t=e.button;return null==e.which&&be.test(e.type)?null!=e.charCode?e.charCode:e.keyCode:!e.which&&void 0!==t&&we.test(e.type)?1&t?1:2&t?3:4&t?2:0:e.which}},S.event.addProp),S.each({focus:"focusin",blur:"focusout"},function(e,t){S.event.special[e]={setup:function(){return Ae(this,e,Se),!1},trigger:function(){return Ae(this,e),!0},delegateType:t}}),S.each({mouseenter:"mouseover",mouseleave:"mouseout",pointerenter:"pointerover",pointerleave:"pointerout"},function(e,i){S.event.special[e]={delegateType:i,bindType:i,handle:function(e){var t,n=e.relatedTarget,r=e.handleObj;return n&&(n===this||S.contains(this,n))||(e.type=r.origType,t=r.handler.apply(this,arguments),e.type=i),t}}}),S.fn.extend({on:function(e,t,n,r){return ke(this,e,t,n,r)},one:function(e,t,n,r){return ke(this,e,t,n,r,1)},off:function(e,t,n){var r,i;if(e&&e.preventDefault&&e.handleObj)return r=e.handleObj,S(e.delegateTarget).off(r.namespace?r.origType+"."+r.namespace:r.origType,r.selector,r.handler),this;if("object"==typeof e){for(i in e)this.off(i,t,e[i]);return this}return!1!==t&&"function"!=typeof t||(n=t,t=void 0),!1===n&&(n=Ee),this.each(function(){S.event.remove(this,e,n,t)})}});var Ne=/<script|<style|<link/i,De=/checked\s*(?:[^=]|=\s*.checked.)/i,je=/^\s*<!(?:\[CDATA\[|--)|(?:\]\]|--)>\s*$/g;function qe(e,t){return A(e,"table")&&A(11!==t.nodeType?t:t.firstChild,"tr")&&S(e).children("tbody")[0]||e}function Le(e){return e.type=(null!==e.getAttribute("type"))+"/"+e.type,e}function He(e){return"true/"===(e.type||"").slice(0,5)?e.type=e.type.slice(5):e.removeAttribute("type"),e}function Oe(e,t){var n,r,i,o,a,s;if(1===t.nodeType){if(Y.hasData(e)&&(s=Y.get(e).events))for(i in Y.remove(t,"handle events"),s)for(n=0,r=s[i].length;n<r;n++)S.event.add(t,i,s[i][n]);Q.hasData(e)&&(o=Q.access(e),a=S.extend({},o),Q.set(t,a))}}function Pe(n,r,i,o){r=g(r);var e,t,a,s,u,l,c=0,f=n.length,p=f-1,d=r[0],h=m(d);if(h||1<f&&"string"==typeof d&&!y.checkClone&&De.test(d))return n.each(function(e){var t=n.eq(e);h&&(r[0]=d.call(this,e,t.html())),Pe(t,r,i,o)});if(f&&(t=(e=xe(r,n[0].ownerDocument,!1,n,o)).firstChild,1===e.childNodes.length&&(e=t),t||o)){for(s=(a=S.map(ve(e,"script"),Le)).length;c<f;c++)u=e,c!==p&&(u=S.clone(u,!0,!0),s&&S.merge(a,ve(u,"script"))),i.call(n[c],u,c);if(s)for(l=a[a.length-1].ownerDocument,S.map(a,He),c=0;c<s;c++)u=a[c],he.test(u.type||"")&&!Y.access(u,"globalEval")&&S.contains(l,u)&&(u.src&&"module"!==(u.type||"").toLowerCase()?S._evalUrl&&!u.noModule&&S._evalUrl(u.src,{nonce:u.nonce||u.getAttribute("nonce")},l):b(u.textContent.replace(je,""),u,l))}return n}function Re(e,t,n){for(var r,i=t?S.filter(t,e):e,o=0;null!=(r=i[o]);o++)n||1!==r.nodeType||S.cleanData(ve(r)),r.parentNode&&(n&&ie(r)&&ye(ve(r,"script")),r.parentNode.removeChild(r));return e}S.extend({htmlPrefilter:function(e){return e},clone:function(e,t,n){var r,i,o,a,s,u,l,c=e.cloneNode(!0),f=ie(e);if(!(y.noCloneChecked||1!==e.nodeType&&11!==e.nodeType||S.isXMLDoc(e)))for(a=ve(c),r=0,i=(o=ve(e)).length;r<i;r++)s=o[r],u=a[r],void 0,"input"===(l=u.nodeName.toLowerCase())&&pe.test(s.type)?u.checked=s.checked:"input"!==l&&"textarea"!==l||(u.defaultValue=s.defaultValue);if(t)if(n)for(o=o||ve(e),a=a||ve(c),r=0,i=o.length;r<i;r++)Oe(o[r],a[r]);else Oe(e,c);return 0<(a=ve(c,"script")).length&&ye(a,!f&&ve(e,"script")),c},cleanData:function(e){for(var t,n,r,i=S.event.special,o=0;void 0!==(n=e[o]);o++)if(V(n)){if(t=n[Y.expando]){if(t.events)for(r in t.events)i[r]?S.event.remove(n,r):S.removeEvent(n,r,t.handle);n[Y.expando]=void 0}n[Q.expando]&&(n[Q.expando]=void 0)}}}),S.fn.extend({detach:function(e){return Re(this,e,!0)},remove:function(e){return Re(this,e)},text:function(e){return $(this,function(e){return void 0===e?S.text(this):this.empty().each(function(){1!==this.nodeType&&11!==this.nodeType&&9!==this.nodeType||(this.textContent=e)})},null,e,arguments.length)},append:function(){return Pe(this,arguments,function(e){1!==this.nodeType&&11!==this.nodeType&&9!==this.nodeType||qe(this,e).appendChild(e)})},prepend:function(){return Pe(this,arguments,function(e){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var t=qe(this,e);t.insertBefore(e,t.firstChild)}})},before:function(){return Pe(this,arguments,function(e){this.parentNode&&this.parentNode.insertBefore(e,this)})},after:function(){return Pe(this,arguments,function(e){this.parentNode&&this.parentNode.insertBefore(e,this.nextSibling)})},empty:function(){for(var e,t=0;null!=(e=this[t]);t++)1===e.nodeType&&(S.cleanData(ve(e,!1)),e.textContent="");return this},clone:function(e,t){return e=null!=e&&e,t=null==t?e:t,this.map(function(){return S.clone(this,e,t)})},html:function(e){return $(this,function(e){var t=this[0]||{},n=0,r=this.length;if(void 0===e&&1===t.nodeType)return t.innerHTML;if("string"==typeof e&&!Ne.test(e)&&!ge[(de.exec(e)||["",""])[1].toLowerCase()]){e=S.htmlPrefilter(e);try{for(;n<r;n++)1===(t=this[n]||{}).nodeType&&(S.cleanData(ve(t,!1)),t.innerHTML=e);t=0}catch(e){}}t&&this.empty().append(e)},null,e,arguments.length)},replaceWith:function(){var n=[];return Pe(this,arguments,function(e){var t=this.parentNode;S.inArray(this,n)<0&&(S.cleanData(ve(this)),t&&t.replaceChild(e,this))},n)}}),S.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(e,a){S.fn[e]=function(e){for(var t,n=[],r=S(e),i=r.length-1,o=0;o<=i;o++)t=o===i?this:this.clone(!0),S(r[o])[a](t),u.apply(n,t.get());return this.pushStack(n)}});var Me=new RegExp("^("+ee+")(?!px)[a-z%]+$","i"),Ie=function(e){var t=e.ownerDocument.defaultView;return t&&t.opener||(t=C),t.getComputedStyle(e)},We=function(e,t,n){var r,i,o={};for(i in t)o[i]=e.style[i],e.style[i]=t[i];for(i in r=n.call(e),t)e.style[i]=o[i];return r},Fe=new RegExp(ne.join("|"),"i");function Be(e,t,n){var r,i,o,a,s=e.style;return(n=n||Ie(e))&&(""!==(a=n.getPropertyValue(t)||n[t])||ie(e)||(a=S.style(e,t)),!y.pixelBoxStyles()&&Me.test(a)&&Fe.test(t)&&(r=s.width,i=s.minWidth,o=s.maxWidth,s.minWidth=s.maxWidth=s.width=a,a=n.width,s.width=r,s.minWidth=i,s.maxWidth=o)),void 0!==a?a+"":a}function $e(e,t){return{get:function(){if(!e())return(this.get=t).apply(this,arguments);delete this.get}}}!function(){function e(){if(l){u.style.cssText="position:absolute;left:-11111px;width:60px;margin-top:1px;padding:0;border:0",l.style.cssText="position:relative;display:block;box-sizing:border-box;overflow:scroll;margin:auto;border:1px;padding:1px;width:60%;top:1%",re.appendChild(u).appendChild(l);var e=C.getComputedStyle(l);n="1%"!==e.top,s=12===t(e.marginLeft),l.style.right="60%",o=36===t(e.right),r=36===t(e.width),l.style.position="absolute",i=12===t(l.offsetWidth/3),re.removeChild(u),l=null}}function t(e){return Math.round(parseFloat(e))}var n,r,i,o,a,s,u=E.createElement("div"),l=E.createElement("div");l.style&&(l.style.backgroundClip="content-box",l.cloneNode(!0).style.backgroundClip="",y.clearCloneStyle="content-box"===l.style.backgroundClip,S.extend(y,{boxSizingReliable:function(){return e(),r},pixelBoxStyles:function(){return e(),o},pixelPosition:function(){return e(),n},reliableMarginLeft:function(){return e(),s},scrollboxSize:function(){return e(),i},reliableTrDimensions:function(){var e,t,n,r;return null==a&&(e=E.createElement("table"),t=E.createElement("tr"),n=E.createElement("div"),e.style.cssText="position:absolute;left:-11111px",t.style.height="1px",n.style.height="9px",re.appendChild(e).appendChild(t).appendChild(n),r=C.getComputedStyle(t),a=3<parseInt(r.height),re.removeChild(e)),a}}))}();var _e=["Webkit","Moz","ms"],ze=E.createElement("div").style,Ue={};function Xe(e){var t=S.cssProps[e]||Ue[e];return t||(e in ze?e:Ue[e]=function(e){var t=e[0].toUpperCase()+e.slice(1),n=_e.length;while(n--)if((e=_e[n]+t)in ze)return e}(e)||e)}var Ve=/^(none|table(?!-c[ea]).+)/,Ge=/^--/,Ye={position:"absolute",visibility:"hidden",display:"block"},Qe={letterSpacing:"0",fontWeight:"400"};function Je(e,t,n){var r=te.exec(t);return r?Math.max(0,r[2]-(n||0))+(r[3]||"px"):t}function Ke(e,t,n,r,i,o){var a="width"===t?1:0,s=0,u=0;if(n===(r?"border":"content"))return 0;for(;a<4;a+=2)"margin"===n&&(u+=S.css(e,n+ne[a],!0,i)),r?("content"===n&&(u-=S.css(e,"padding"+ne[a],!0,i)),"margin"!==n&&(u-=S.css(e,"border"+ne[a]+"Width",!0,i))):(u+=S.css(e,"padding"+ne[a],!0,i),"padding"!==n?u+=S.css(e,"border"+ne[a]+"Width",!0,i):s+=S.css(e,"border"+ne[a]+"Width",!0,i));return!r&&0<=o&&(u+=Math.max(0,Math.ceil(e["offset"+t[0].toUpperCase()+t.slice(1)]-o-u-s-.5))||0),u}function Ze(e,t,n){var r=Ie(e),i=(!y.boxSizingReliable()||n)&&"border-box"===S.css(e,"boxSizing",!1,r),o=i,a=Be(e,t,r),s="offset"+t[0].toUpperCase()+t.slice(1);if(Me.test(a)){if(!n)return a;a="auto"}return(!y.boxSizingReliable()&&i||!y.reliableTrDimensions()&&A(e,"tr")||"auto"===a||!parseFloat(a)&&"inline"===S.css(e,"display",!1,r))&&e.getClientRects().length&&(i="border-box"===S.css(e,"boxSizing",!1,r),(o=s in e)&&(a=e[s])),(a=parseFloat(a)||0)+Ke(e,t,n||(i?"border":"content"),o,r,a)+"px"}function et(e,t,n,r,i){return new et.prototype.init(e,t,n,r,i)}S.extend({cssHooks:{opacity:{get:function(e,t){if(t){var n=Be(e,"opacity");return""===n?"1":n}}}},cssNumber:{animationIterationCount:!0,columnCount:!0,fillOpacity:!0,flexGrow:!0,flexShrink:!0,fontWeight:!0,gridArea:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnStart:!0,gridRow:!0,gridRowEnd:!0,gridRowStart:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,widows:!0,zIndex:!0,zoom:!0},cssProps:{},style:function(e,t,n,r){if(e&&3!==e.nodeType&&8!==e.nodeType&&e.style){var i,o,a,s=X(t),u=Ge.test(t),l=e.style;if(u||(t=Xe(s)),a=S.cssHooks[t]||S.cssHooks[s],void 0===n)return a&&"get"in a&&void 0!==(i=a.get(e,!1,r))?i:l[t];"string"===(o=typeof n)&&(i=te.exec(n))&&i[1]&&(n=se(e,t,i),o="number"),null!=n&&n==n&&("number"!==o||u||(n+=i&&i[3]||(S.cssNumber[s]?"":"px")),y.clearCloneStyle||""!==n||0!==t.indexOf("background")||(l[t]="inherit"),a&&"set"in a&&void 0===(n=a.set(e,n,r))||(u?l.setProperty(t,n):l[t]=n))}},css:function(e,t,n,r){var i,o,a,s=X(t);return Ge.test(t)||(t=Xe(s)),(a=S.cssHooks[t]||S.cssHooks[s])&&"get"in a&&(i=a.get(e,!0,n)),void 0===i&&(i=Be(e,t,r)),"normal"===i&&t in Qe&&(i=Qe[t]),""===n||n?(o=parseFloat(i),!0===n||isFinite(o)?o||0:i):i}}),S.each(["height","width"],function(e,u){S.cssHooks[u]={get:function(e,t,n){if(t)return!Ve.test(S.css(e,"display"))||e.getClientRects().length&&e.getBoundingClientRect().width?Ze(e,u,n):We(e,Ye,function(){return Ze(e,u,n)})},set:function(e,t,n){var r,i=Ie(e),o=!y.scrollboxSize()&&"absolute"===i.position,a=(o||n)&&"border-box"===S.css(e,"boxSizing",!1,i),s=n?Ke(e,u,n,a,i):0;return a&&o&&(s-=Math.ceil(e["offset"+u[0].toUpperCase()+u.slice(1)]-parseFloat(i[u])-Ke(e,u,"border",!1,i)-.5)),s&&(r=te.exec(t))&&"px"!==(r[3]||"px")&&(e.style[u]=t,t=S.css(e,u)),Je(0,t,s)}}}),S.cssHooks.marginLeft=$e(y.reliableMarginLeft,function(e,t){if(t)return(parseFloat(Be(e,"marginLeft"))||e.getBoundingClientRect().left-We(e,{marginLeft:0},function(){return e.getBoundingClientRect().left}))+"px"}),S.each({margin:"",padding:"",border:"Width"},function(i,o){S.cssHooks[i+o]={expand:function(e){for(var t=0,n={},r="string"==typeof e?e.split(" "):[e];t<4;t++)n[i+ne[t]+o]=r[t]||r[t-2]||r[0];return n}},"margin"!==i&&(S.cssHooks[i+o].set=Je)}),S.fn.extend({css:function(e,t){return $(this,function(e,t,n){var r,i,o={},a=0;if(Array.isArray(t)){for(r=Ie(e),i=t.length;a<i;a++)o[t[a]]=S.css(e,t[a],!1,r);return o}return void 0!==n?S.style(e,t,n):S.css(e,t)},e,t,1<arguments.length)}}),((S.Tween=et).prototype={constructor:et,init:function(e,t,n,r,i,o){this.elem=e,this.prop=n,this.easing=i||S.easing._default,this.options=t,this.start=this.now=this.cur(),this.end=r,this.unit=o||(S.cssNumber[n]?"":"px")},cur:function(){var e=et.propHooks[this.prop];return e&&e.get?e.get(this):et.propHooks._default.get(this)},run:function(e){var t,n=et.propHooks[this.prop];return this.options.duration?this.pos=t=S.easing[this.easing](e,this.options.duration*e,0,1,this.options.duration):this.pos=t=e,this.now=(this.end-this.start)*t+this.start,this.options.step&&this.options.step.call(this.elem,this.now,this),n&&n.set?n.set(this):et.propHooks._default.set(this),this}}).init.prototype=et.prototype,(et.propHooks={_default:{get:function(e){var t;return 1!==e.elem.nodeType||null!=e.elem[e.prop]&&null==e.elem.style[e.prop]?e.elem[e.prop]:(t=S.css(e.elem,e.prop,""))&&"auto"!==t?t:0},set:function(e){S.fx.step[e.prop]?S.fx.step[e.prop](e):1!==e.elem.nodeType||!S.cssHooks[e.prop]&&null==e.elem.style[Xe(e.prop)]?e.elem[e.prop]=e.now:S.style(e.elem,e.prop,e.now+e.unit)}}}).scrollTop=et.propHooks.scrollLeft={set:function(e){e.elem.nodeType&&e.elem.parentNode&&(e.elem[e.prop]=e.now)}},S.easing={linear:function(e){return e},swing:function(e){return.5-Math.cos(e*Math.PI)/2},_default:"swing"},S.fx=et.prototype.init,S.fx.step={};var tt,nt,rt,it,ot=/^(?:toggle|show|hide)$/,at=/queueHooks$/;function st(){nt&&(!1===E.hidden&&C.requestAnimationFrame?C.requestAnimationFrame(st):C.setTimeout(st,S.fx.interval),S.fx.tick())}function ut(){return C.setTimeout(function(){tt=void 0}),tt=Date.now()}function lt(e,t){var n,r=0,i={height:e};for(t=t?1:0;r<4;r+=2-t)i["margin"+(n=ne[r])]=i["padding"+n]=e;return t&&(i.opacity=i.width=e),i}function ct(e,t,n){for(var r,i=(ft.tweeners[t]||[]).concat(ft.tweeners["*"]),o=0,a=i.length;o<a;o++)if(r=i[o].call(n,t,e))return r}function ft(o,e,t){var n,a,r=0,i=ft.prefilters.length,s=S.Deferred().always(function(){delete u.elem}),u=function(){if(a)return!1;for(var e=tt||ut(),t=Math.max(0,l.startTime+l.duration-e),n=1-(t/l.duration||0),r=0,i=l.tweens.length;r<i;r++)l.tweens[r].run(n);return s.notifyWith(o,[l,n,t]),n<1&&i?t:(i||s.notifyWith(o,[l,1,0]),s.resolveWith(o,[l]),!1)},l=s.promise({elem:o,props:S.extend({},e),opts:S.extend(!0,{specialEasing:{},easing:S.easing._default},t),originalProperties:e,originalOptions:t,startTime:tt||ut(),duration:t.duration,tweens:[],createTween:function(e,t){var n=S.Tween(o,l.opts,e,t,l.opts.specialEasing[e]||l.opts.easing);return l.tweens.push(n),n},stop:function(e){var t=0,n=e?l.tweens.length:0;if(a)return this;for(a=!0;t<n;t++)l.tweens[t].run(1);return e?(s.notifyWith(o,[l,1,0]),s.resolveWith(o,[l,e])):s.rejectWith(o,[l,e]),this}}),c=l.props;for(!function(e,t){var n,r,i,o,a;for(n in e)if(i=t[r=X(n)],o=e[n],Array.isArray(o)&&(i=o[1],o=e[n]=o[0]),n!==r&&(e[r]=o,delete e[n]),(a=S.cssHooks[r])&&"expand"in a)for(n in o=a.expand(o),delete e[r],o)n in e||(e[n]=o[n],t[n]=i);else t[r]=i}(c,l.opts.specialEasing);r<i;r++)if(n=ft.prefilters[r].call(l,o,c,l.opts))return m(n.stop)&&(S._queueHooks(l.elem,l.opts.queue).stop=n.stop.bind(n)),n;return S.map(c,ct,l),m(l.opts.start)&&l.opts.start.call(o,l),l.progress(l.opts.progress).done(l.opts.done,l.opts.complete).fail(l.opts.fail).always(l.opts.always),S.fx.timer(S.extend(u,{elem:o,anim:l,queue:l.opts.queue})),l}S.Animation=S.extend(ft,{tweeners:{"*":[function(e,t){var n=this.createTween(e,t);return se(n.elem,e,te.exec(t),n),n}]},tweener:function(e,t){m(e)?(t=e,e=["*"]):e=e.match(P);for(var n,r=0,i=e.length;r<i;r++)n=e[r],ft.tweeners[n]=ft.tweeners[n]||[],ft.tweeners[n].unshift(t)},prefilters:[function(e,t,n){var r,i,o,a,s,u,l,c,f="width"in t||"height"in t,p=this,d={},h=e.style,g=e.nodeType&&ae(e),v=Y.get(e,"fxshow");for(r in n.queue||(null==(a=S._queueHooks(e,"fx")).unqueued&&(a.unqueued=0,s=a.empty.fire,a.empty.fire=function(){a.unqueued||s()}),a.unqueued++,p.always(function(){p.always(function(){a.unqueued--,S.queue(e,"fx").length||a.empty.fire()})})),t)if(i=t[r],ot.test(i)){if(delete t[r],o=o||"toggle"===i,i===(g?"hide":"show")){if("show"!==i||!v||void 0===v[r])continue;g=!0}d[r]=v&&v[r]||S.style(e,r)}if((u=!S.isEmptyObject(t))||!S.isEmptyObject(d))for(r in f&&1===e.nodeType&&(n.overflow=[h.overflow,h.overflowX,h.overflowY],null==(l=v&&v.display)&&(l=Y.get(e,"display")),"none"===(c=S.css(e,"display"))&&(l?c=l:(le([e],!0),l=e.style.display||l,c=S.css(e,"display"),le([e]))),("inline"===c||"inline-block"===c&&null!=l)&&"none"===S.css(e,"float")&&(u||(p.done(function(){h.display=l}),null==l&&(c=h.display,l="none"===c?"":c)),h.display="inline-block")),n.overflow&&(h.overflow="hidden",p.always(function(){h.overflow=n.overflow[0],h.overflowX=n.overflow[1],h.overflowY=n.overflow[2]})),u=!1,d)u||(v?"hidden"in v&&(g=v.hidden):v=Y.access(e,"fxshow",{display:l}),o&&(v.hidden=!g),g&&le([e],!0),p.done(function(){for(r in g||le([e]),Y.remove(e,"fxshow"),d)S.style(e,r,d[r])})),u=ct(g?v[r]:0,r,p),r in v||(v[r]=u.start,g&&(u.end=u.start,u.start=0))}],prefilter:function(e,t){t?ft.prefilters.unshift(e):ft.prefilters.push(e)}}),S.speed=function(e,t,n){var r=e&&"object"==typeof e?S.extend({},e):{complete:n||!n&&t||m(e)&&e,duration:e,easing:n&&t||t&&!m(t)&&t};return S.fx.off?r.duration=0:"number"!=typeof r.duration&&(r.duration in S.fx.speeds?r.duration=S.fx.speeds[r.duration]:r.duration=S.fx.speeds._default),null!=r.queue&&!0!==r.queue||(r.queue="fx"),r.old=r.complete,r.complete=function(){m(r.old)&&r.old.call(this),r.queue&&S.dequeue(this,r.queue)},r},S.fn.extend({fadeTo:function(e,t,n,r){return this.filter(ae).css("opacity",0).show().end().animate({opacity:t},e,n,r)},animate:function(t,e,n,r){var i=S.isEmptyObject(t),o=S.speed(e,n,r),a=function(){var e=ft(this,S.extend({},t),o);(i||Y.get(this,"finish"))&&e.stop(!0)};return a.finish=a,i||!1===o.queue?this.each(a):this.queue(o.queue,a)},stop:function(i,e,o){var a=function(e){var t=e.stop;delete e.stop,t(o)};return"string"!=typeof i&&(o=e,e=i,i=void 0),e&&this.queue(i||"fx",[]),this.each(function(){var e=!0,t=null!=i&&i+"queueHooks",n=S.timers,r=Y.get(this);if(t)r[t]&&r[t].stop&&a(r[t]);else for(t in r)r[t]&&r[t].stop&&at.test(t)&&a(r[t]);for(t=n.length;t--;)n[t].elem!==this||null!=i&&n[t].queue!==i||(n[t].anim.stop(o),e=!1,n.splice(t,1));!e&&o||S.dequeue(this,i)})},finish:function(a){return!1!==a&&(a=a||"fx"),this.each(function(){var e,t=Y.get(this),n=t[a+"queue"],r=t[a+"queueHooks"],i=S.timers,o=n?n.length:0;for(t.finish=!0,S.queue(this,a,[]),r&&r.stop&&r.stop.call(this,!0),e=i.length;e--;)i[e].elem===this&&i[e].queue===a&&(i[e].anim.stop(!0),i.splice(e,1));for(e=0;e<o;e++)n[e]&&n[e].finish&&n[e].finish.call(this);delete t.finish})}}),S.each(["toggle","show","hide"],function(e,r){var i=S.fn[r];S.fn[r]=function(e,t,n){return null==e||"boolean"==typeof e?i.apply(this,arguments):this.animate(lt(r,!0),e,t,n)}}),S.each({slideDown:lt("show"),slideUp:lt("hide"),slideToggle:lt("toggle"),fadeIn:{opacity:"show"},fadeOut:{opacity:"hide"},fadeToggle:{opacity:"toggle"}},function(e,r){S.fn[e]=function(e,t,n){return this.animate(r,e,t,n)}}),S.timers=[],S.fx.tick=function(){var e,t=0,n=S.timers;for(tt=Date.now();t<n.length;t++)(e=n[t])()||n[t]!==e||n.splice(t--,1);n.length||S.fx.stop(),tt=void 0},S.fx.timer=function(e){S.timers.push(e),S.fx.start()},S.fx.interval=13,S.fx.start=function(){nt||(nt=!0,st())},S.fx.stop=function(){nt=null},S.fx.speeds={slow:600,fast:200,_default:400},S.fn.delay=function(r,e){return r=S.fx&&S.fx.speeds[r]||r,e=e||"fx",this.queue(e,function(e,t){var n=C.setTimeout(e,r);t.stop=function(){C.clearTimeout(n)}})},rt=E.createElement("input"),it=E.createElement("select").appendChild(E.createElement("option")),rt.type="checkbox",y.checkOn=""!==rt.value,y.optSelected=it.selected,(rt=E.createElement("input")).value="t",rt.type="radio",y.radioValue="t"===rt.value;var pt,dt=S.expr.attrHandle;S.fn.extend({attr:function(e,t){return $(this,S.attr,e,t,1<arguments.length)},removeAttr:function(e){return this.each(function(){S.removeAttr(this,e)})}}),S.extend({attr:function(e,t,n){var r,i,o=e.nodeType;if(3!==o&&8!==o&&2!==o)return"undefined"==typeof e.getAttribute?S.prop(e,t,n):(1===o&&S.isXMLDoc(e)||(i=S.attrHooks[t.toLowerCase()]||(S.expr.match.bool.test(t)?pt:void 0)),void 0!==n?null===n?void S.removeAttr(e,t):i&&"set"in i&&void 0!==(r=i.set(e,n,t))?r:(e.setAttribute(t,n+""),n):i&&"get"in i&&null!==(r=i.get(e,t))?r:null==(r=S.find.attr(e,t))?void 0:r)},attrHooks:{type:{set:function(e,t){if(!y.radioValue&&"radio"===t&&A(e,"input")){var n=e.value;return e.setAttribute("type",t),n&&(e.value=n),t}}}},removeAttr:function(e,t){var n,r=0,i=t&&t.match(P);if(i&&1===e.nodeType)while(n=i[r++])e.removeAttribute(n)}}),pt={set:function(e,t,n){return!1===t?S.removeAttr(e,n):e.setAttribute(n,n),n}},S.each(S.expr.match.bool.source.match(/\w+/g),function(e,t){var a=dt[t]||S.find.attr;dt[t]=function(e,t,n){var r,i,o=t.toLowerCase();return n||(i=dt[o],dt[o]=r,r=null!=a(e,t,n)?o:null,dt[o]=i),r}});var ht=/^(?:input|select|textarea|button)$/i,gt=/^(?:a|area)$/i;function vt(e){return(e.match(P)||[]).join(" ")}function yt(e){return e.getAttribute&&e.getAttribute("class")||""}function mt(e){return Array.isArray(e)?e:"string"==typeof e&&e.match(P)||[]}S.fn.extend({prop:function(e,t){return $(this,S.prop,e,t,1<arguments.length)},removeProp:function(e){return this.each(function(){delete this[S.propFix[e]||e]})}}),S.extend({prop:function(e,t,n){var r,i,o=e.nodeType;if(3!==o&&8!==o&&2!==o)return 1===o&&S.isXMLDoc(e)||(t=S.propFix[t]||t,i=S.propHooks[t]),void 0!==n?i&&"set"in i&&void 0!==(r=i.set(e,n,t))?r:e[t]=n:i&&"get"in i&&null!==(r=i.get(e,t))?r:e[t]},propHooks:{tabIndex:{get:function(e){var t=S.find.attr(e,"tabindex");return t?parseInt(t,10):ht.test(e.nodeName)||gt.test(e.nodeName)&&e.href?0:-1}}},propFix:{"for":"htmlFor","class":"className"}}),y.optSelected||(S.propHooks.selected={get:function(e){var t=e.parentNode;return t&&t.parentNode&&t.parentNode.selectedIndex,null},set:function(e){var t=e.parentNode;t&&(t.selectedIndex,t.parentNode&&t.parentNode.selectedIndex)}}),S.each(["tabIndex","readOnly","maxLength","cellSpacing","cellPadding","rowSpan","colSpan","useMap","frameBorder","contentEditable"],function(){S.propFix[this.toLowerCase()]=this}),S.fn.extend({addClass:function(t){var e,n,r,i,o,a,s,u=0;if(m(t))return this.each(function(e){S(this).addClass(t.call(this,e,yt(this)))});if((e=mt(t)).length)while(n=this[u++])if(i=yt(n),r=1===n.nodeType&&" "+vt(i)+" "){a=0;while(o=e[a++])r.indexOf(" "+o+" ")<0&&(r+=o+" ");i!==(s=vt(r))&&n.setAttribute("class",s)}return this},removeClass:function(t){var e,n,r,i,o,a,s,u=0;if(m(t))return this.each(function(e){S(this).removeClass(t.call(this,e,yt(this)))});if(!arguments.length)return this.attr("class","");if((e=mt(t)).length)while(n=this[u++])if(i=yt(n),r=1===n.nodeType&&" "+vt(i)+" "){a=0;while(o=e[a++])while(-1<r.indexOf(" "+o+" "))r=r.replace(" "+o+" "," ");i!==(s=vt(r))&&n.setAttribute("class",s)}return this},toggleClass:function(i,t){var o=typeof i,a="string"===o||Array.isArray(i);return"boolean"==typeof t&&a?t?this.addClass(i):this.removeClass(i):m(i)?this.each(function(e){S(this).toggleClass(i.call(this,e,yt(this),t),t)}):this.each(function(){var e,t,n,r;if(a){t=0,n=S(this),r=mt(i);while(e=r[t++])n.hasClass(e)?n.removeClass(e):n.addClass(e)}else void 0!==i&&"boolean"!==o||((e=yt(this))&&Y.set(this,"__className__",e),this.setAttribute&&this.setAttribute("class",e||!1===i?"":Y.get(this,"__className__")||""))})},hasClass:function(e){var t,n,r=0;t=" "+e+" ";while(n=this[r++])if(1===n.nodeType&&-1<(" "+vt(yt(n))+" ").indexOf(t))return!0;return!1}});var xt=/\r/g;S.fn.extend({val:function(n){var r,e,i,t=this[0];return arguments.length?(i=m(n),this.each(function(e){var t;1===this.nodeType&&(null==(t=i?n.call(this,e,S(this).val()):n)?t="":"number"==typeof t?t+="":Array.isArray(t)&&(t=S.map(t,function(e){return null==e?"":e+""})),(r=S.valHooks[this.type]||S.valHooks[this.nodeName.toLowerCase()])&&"set"in r&&void 0!==r.set(this,t,"value")||(this.value=t))})):t?(r=S.valHooks[t.type]||S.valHooks[t.nodeName.toLowerCase()])&&"get"in r&&void 0!==(e=r.get(t,"value"))?e:"string"==typeof(e=t.value)?e.replace(xt,""):null==e?"":e:void 0}}),S.extend({valHooks:{option:{get:function(e){var t=S.find.attr(e,"value");return null!=t?t:vt(S.text(e))}},select:{get:function(e){var t,n,r,i=e.options,o=e.selectedIndex,a="select-one"===e.type,s=a?null:[],u=a?o+1:i.length;for(r=o<0?u:a?o:0;r<u;r++)if(((n=i[r]).selected||r===o)&&!n.disabled&&(!n.parentNode.disabled||!A(n.parentNode,"optgroup"))){if(t=S(n).val(),a)return t;s.push(t)}return s},set:function(e,t){var n,r,i=e.options,o=S.makeArray(t),a=i.length;while(a--)((r=i[a]).selected=-1<S.inArray(S.valHooks.option.get(r),o))&&(n=!0);return n||(e.selectedIndex=-1),o}}}}),S.each(["radio","checkbox"],function(){S.valHooks[this]={set:function(e,t){if(Array.isArray(t))return e.checked=-1<S.inArray(S(e).val(),t)}},y.checkOn||(S.valHooks[this].get=function(e){return null===e.getAttribute("value")?"on":e.value})}),y.focusin="onfocusin"in C;var bt=/^(?:focusinfocus|focusoutblur)$/,wt=function(e){e.stopPropagation()};S.extend(S.event,{trigger:function(e,t,n,r){var i,o,a,s,u,l,c,f,p=[n||E],d=v.call(e,"type")?e.type:e,h=v.call(e,"namespace")?e.namespace.split("."):[];if(o=f=a=n=n||E,3!==n.nodeType&&8!==n.nodeType&&!bt.test(d+S.event.triggered)&&(-1<d.indexOf(".")&&(d=(h=d.split(".")).shift(),h.sort()),u=d.indexOf(":")<0&&"on"+d,(e=e[S.expando]?e:new S.Event(d,"object"==typeof e&&e)).isTrigger=r?2:3,e.namespace=h.join("."),e.rnamespace=e.namespace?new RegExp("(^|\\.)"+h.join("\\.(?:.*\\.|)")+"(\\.|$)"):null,e.result=void 0,e.target||(e.target=n),t=null==t?[e]:S.makeArray(t,[e]),c=S.event.special[d]||{},r||!c.trigger||!1!==c.trigger.apply(n,t))){if(!r&&!c.noBubble&&!x(n)){for(s=c.delegateType||d,bt.test(s+d)||(o=o.parentNode);o;o=o.parentNode)p.push(o),a=o;a===(n.ownerDocument||E)&&p.push(a.defaultView||a.parentWindow||C)}i=0;while((o=p[i++])&&!e.isPropagationStopped())f=o,e.type=1<i?s:c.bindType||d,(l=(Y.get(o,"events")||Object.create(null))[e.type]&&Y.get(o,"handle"))&&l.apply(o,t),(l=u&&o[u])&&l.apply&&V(o)&&(e.result=l.apply(o,t),!1===e.result&&e.preventDefault());return e.type=d,r||e.isDefaultPrevented()||c._default&&!1!==c._default.apply(p.pop(),t)||!V(n)||u&&m(n[d])&&!x(n)&&((a=n[u])&&(n[u]=null),S.event.triggered=d,e.isPropagationStopped()&&f.addEventListener(d,wt),n[d](),e.isPropagationStopped()&&f.removeEventListener(d,wt),S.event.triggered=void 0,a&&(n[u]=a)),e.result}},simulate:function(e,t,n){var r=S.extend(new S.Event,n,{type:e,isSimulated:!0});S.event.trigger(r,null,t)}}),S.fn.extend({trigger:function(e,t){return this.each(function(){S.event.trigger(e,t,this)})},triggerHandler:function(e,t){var n=this[0];if(n)return S.event.trigger(e,t,n,!0)}}),y.focusin||S.each({focus:"focusin",blur:"focusout"},function(n,r){var i=function(e){S.event.simulate(r,e.target,S.event.fix(e))};S.event.special[r]={setup:function(){var e=this.ownerDocument||this.document||this,t=Y.access(e,r);t||e.addEventListener(n,i,!0),Y.access(e,r,(t||0)+1)},teardown:function(){var e=this.ownerDocument||this.document||this,t=Y.access(e,r)-1;t?Y.access(e,r,t):(e.removeEventListener(n,i,!0),Y.remove(e,r))}}});var Tt=C.location,Ct={guid:Date.now()},Et=/\?/;S.parseXML=function(e){var t;if(!e||"string"!=typeof e)return null;try{t=(new C.DOMParser).parseFromString(e,"text/xml")}catch(e){t=void 0}return t&&!t.getElementsByTagName("parsererror").length||S.error("Invalid XML: "+e),t};var St=/\[\]$/,kt=/\r?\n/g,At=/^(?:submit|button|image|reset|file)$/i,Nt=/^(?:input|select|textarea|keygen)/i;function Dt(n,e,r,i){var t;if(Array.isArray(e))S.each(e,function(e,t){r||St.test(n)?i(n,t):Dt(n+"["+("object"==typeof t&&null!=t?e:"")+"]",t,r,i)});else if(r||"object"!==w(e))i(n,e);else for(t in e)Dt(n+"["+t+"]",e[t],r,i)}S.param=function(e,t){var n,r=[],i=function(e,t){var n=m(t)?t():t;r[r.length]=encodeURIComponent(e)+"="+encodeURIComponent(null==n?"":n)};if(null==e)return"";if(Array.isArray(e)||e.jquery&&!S.isPlainObject(e))S.each(e,function(){i(this.name,this.value)});else for(n in e)Dt(n,e[n],t,i);return r.join("&")},S.fn.extend({serialize:function(){return S.param(this.serializeArray())},serializeArray:function(){return this.map(function(){var e=S.prop(this,"elements");return e?S.makeArray(e):this}).filter(function(){var e=this.type;return this.name&&!S(this).is(":disabled")&&Nt.test(this.nodeName)&&!At.test(e)&&(this.checked||!pe.test(e))}).map(function(e,t){var n=S(this).val();return null==n?null:Array.isArray(n)?S.map(n,function(e){return{name:t.name,value:e.replace(kt,"\r\n")}}):{name:t.name,value:n.replace(kt,"\r\n")}}).get()}});var jt=/%20/g,qt=/#.*$/,Lt=/([?&])_=[^&]*/,Ht=/^(.*?):[ \t]*([^\r\n]*)$/gm,Ot=/^(?:GET|HEAD)$/,Pt=/^\/\//,Rt={},Mt={},It="*/".concat("*"),Wt=E.createElement("a");function Ft(o){return function(e,t){"string"!=typeof e&&(t=e,e="*");var n,r=0,i=e.toLowerCase().match(P)||[];if(m(t))while(n=i[r++])"+"===n[0]?(n=n.slice(1)||"*",(o[n]=o[n]||[]).unshift(t)):(o[n]=o[n]||[]).push(t)}}function Bt(t,i,o,a){var s={},u=t===Mt;function l(e){var r;return s[e]=!0,S.each(t[e]||[],function(e,t){var n=t(i,o,a);return"string"!=typeof n||u||s[n]?u?!(r=n):void 0:(i.dataTypes.unshift(n),l(n),!1)}),r}return l(i.dataTypes[0])||!s["*"]&&l("*")}function $t(e,t){var n,r,i=S.ajaxSettings.flatOptions||{};for(n in t)void 0!==t[n]&&((i[n]?e:r||(r={}))[n]=t[n]);return r&&S.extend(!0,e,r),e}Wt.href=Tt.href,S.extend({active:0,lastModified:{},etag:{},ajaxSettings:{url:Tt.href,type:"GET",isLocal:/^(?:about|app|app-storage|.+-extension|file|res|widget):$/.test(Tt.protocol),global:!0,processData:!0,async:!0,contentType:"application/x-www-form-urlencoded; charset=UTF-8",accepts:{"*":It,text:"text/plain",html:"text/html",xml:"application/xml, text/xml",json:"application/json, text/javascript"},contents:{xml:/\bxml\b/,html:/\bhtml/,json:/\bjson\b/},responseFields:{xml:"responseXML",text:"responseText",json:"responseJSON"},converters:{"* text":String,"text html":!0,"text json":JSON.parse,"text xml":S.parseXML},flatOptions:{url:!0,context:!0}},ajaxSetup:function(e,t){return t?$t($t(e,S.ajaxSettings),t):$t(S.ajaxSettings,e)},ajaxPrefilter:Ft(Rt),ajaxTransport:Ft(Mt),ajax:function(e,t){"object"==typeof e&&(t=e,e=void 0),t=t||{};var c,f,p,n,d,r,h,g,i,o,v=S.ajaxSetup({},t),y=v.context||v,m=v.context&&(y.nodeType||y.jquery)?S(y):S.event,x=S.Deferred(),b=S.Callbacks("once memory"),w=v.statusCode||{},a={},s={},u="canceled",T={readyState:0,getResponseHeader:function(e){var t;if(h){if(!n){n={};while(t=Ht.exec(p))n[t[1].toLowerCase()+" "]=(n[t[1].toLowerCase()+" "]||[]).concat(t[2])}t=n[e.toLowerCase()+" "]}return null==t?null:t.join(", ")},getAllResponseHeaders:function(){return h?p:null},setRequestHeader:function(e,t){return null==h&&(e=s[e.toLowerCase()]=s[e.toLowerCase()]||e,a[e]=t),this},overrideMimeType:function(e){return null==h&&(v.mimeType=e),this},statusCode:function(e){var t;if(e)if(h)T.always(e[T.status]);else for(t in e)w[t]=[w[t],e[t]];return this},abort:function(e){var t=e||u;return c&&c.abort(t),l(0,t),this}};if(x.promise(T),v.url=((e||v.url||Tt.href)+"").replace(Pt,Tt.protocol+"//"),v.type=t.method||t.type||v.method||v.type,v.dataTypes=(v.dataType||"*").toLowerCase().match(P)||[""],null==v.crossDomain){r=E.createElement("a");try{r.href=v.url,r.href=r.href,v.crossDomain=Wt.protocol+"//"+Wt.host!=r.protocol+"//"+r.host}catch(e){v.crossDomain=!0}}if(v.data&&v.processData&&"string"!=typeof v.data&&(v.data=S.param(v.data,v.traditional)),Bt(Rt,v,t,T),h)return T;for(i in(g=S.event&&v.global)&&0==S.active++&&S.event.trigger("ajaxStart"),v.type=v.type.toUpperCase(),v.hasContent=!Ot.test(v.type),f=v.url.replace(qt,""),v.hasContent?v.data&&v.processData&&0===(v.contentType||"").indexOf("application/x-www-form-urlencoded")&&(v.data=v.data.replace(jt,"+")):(o=v.url.slice(f.length),v.data&&(v.processData||"string"==typeof v.data)&&(f+=(Et.test(f)?"&":"?")+v.data,delete v.data),!1===v.cache&&(f=f.replace(Lt,"$1"),o=(Et.test(f)?"&":"?")+"_="+Ct.guid+++o),v.url=f+o),v.ifModified&&(S.lastModified[f]&&T.setRequestHeader("If-Modified-Since",S.lastModified[f]),S.etag[f]&&T.setRequestHeader("If-None-Match",S.etag[f])),(v.data&&v.hasContent&&!1!==v.contentType||t.contentType)&&T.setRequestHeader("Content-Type",v.contentType),T.setRequestHeader("Accept",v.dataTypes[0]&&v.accepts[v.dataTypes[0]]?v.accepts[v.dataTypes[0]]+("*"!==v.dataTypes[0]?", "+It+"; q=0.01":""):v.accepts["*"]),v.headers)T.setRequestHeader(i,v.headers[i]);if(v.beforeSend&&(!1===v.beforeSend.call(y,T,v)||h))return T.abort();if(u="abort",b.add(v.complete),T.done(v.success),T.fail(v.error),c=Bt(Mt,v,t,T)){if(T.readyState=1,g&&m.trigger("ajaxSend",[T,v]),h)return T;v.async&&0<v.timeout&&(d=C.setTimeout(function(){T.abort("timeout")},v.timeout));try{h=!1,c.send(a,l)}catch(e){if(h)throw e;l(-1,e)}}else l(-1,"No Transport");function l(e,t,n,r){var i,o,a,s,u,l=t;h||(h=!0,d&&C.clearTimeout(d),c=void 0,p=r||"",T.readyState=0<e?4:0,i=200<=e&&e<300||304===e,n&&(s=function(e,t,n){var r,i,o,a,s=e.contents,u=e.dataTypes;while("*"===u[0])u.shift(),void 0===r&&(r=e.mimeType||t.getResponseHeader("Content-Type"));if(r)for(i in s)if(s[i]&&s[i].test(r)){u.unshift(i);break}if(u[0]in n)o=u[0];else{for(i in n){if(!u[0]||e.converters[i+" "+u[0]]){o=i;break}a||(a=i)}o=o||a}if(o)return o!==u[0]&&u.unshift(o),n[o]}(v,T,n)),!i&&-1<S.inArray("script",v.dataTypes)&&(v.converters["text script"]=function(){}),s=function(e,t,n,r){var i,o,a,s,u,l={},c=e.dataTypes.slice();if(c[1])for(a in e.converters)l[a.toLowerCase()]=e.converters[a];o=c.shift();while(o)if(e.responseFields[o]&&(n[e.responseFields[o]]=t),!u&&r&&e.dataFilter&&(t=e.dataFilter(t,e.dataType)),u=o,o=c.shift())if("*"===o)o=u;else if("*"!==u&&u!==o){if(!(a=l[u+" "+o]||l["* "+o]))for(i in l)if((s=i.split(" "))[1]===o&&(a=l[u+" "+s[0]]||l["* "+s[0]])){!0===a?a=l[i]:!0!==l[i]&&(o=s[0],c.unshift(s[1]));break}if(!0!==a)if(a&&e["throws"])t=a(t);else try{t=a(t)}catch(e){return{state:"parsererror",error:a?e:"No conversion from "+u+" to "+o}}}return{state:"success",data:t}}(v,s,T,i),i?(v.ifModified&&((u=T.getResponseHeader("Last-Modified"))&&(S.lastModified[f]=u),(u=T.getResponseHeader("etag"))&&(S.etag[f]=u)),204===e||"HEAD"===v.type?l="nocontent":304===e?l="notmodified":(l=s.state,o=s.data,i=!(a=s.error))):(a=l,!e&&l||(l="error",e<0&&(e=0))),T.status=e,T.statusText=(t||l)+"",i?x.resolveWith(y,[o,l,T]):x.rejectWith(y,[T,l,a]),T.statusCode(w),w=void 0,g&&m.trigger(i?"ajaxSuccess":"ajaxError",[T,v,i?o:a]),b.fireWith(y,[T,l]),g&&(m.trigger("ajaxComplete",[T,v]),--S.active||S.event.trigger("ajaxStop")))}return T},getJSON:function(e,t,n){return S.get(e,t,n,"json")},getScript:function(e,t){return S.get(e,void 0,t,"script")}}),S.each(["get","post"],function(e,i){S[i]=function(e,t,n,r){return m(t)&&(r=r||n,n=t,t=void 0),S.ajax(S.extend({url:e,type:i,dataType:r,data:t,success:n},S.isPlainObject(e)&&e))}}),S.ajaxPrefilter(function(e){var t;for(t in e.headers)"content-type"===t.toLowerCase()&&(e.contentType=e.headers[t]||"")}),S._evalUrl=function(e,t,n){return S.ajax({url:e,type:"GET",dataType:"script",cache:!0,async:!1,global:!1,converters:{"text script":function(){}},dataFilter:function(e){S.globalEval(e,t,n)}})},S.fn.extend({wrapAll:function(e){var t;return this[0]&&(m(e)&&(e=e.call(this[0])),t=S(e,this[0].ownerDocument).eq(0).clone(!0),this[0].parentNode&&t.insertBefore(this[0]),t.map(function(){var e=this;while(e.firstElementChild)e=e.firstElementChild;return e}).append(this)),this},wrapInner:function(n){return m(n)?this.each(function(e){S(this).wrapInner(n.call(this,e))}):this.each(function(){var e=S(this),t=e.contents();t.length?t.wrapAll(n):e.append(n)})},wrap:function(t){var n=m(t);return this.each(function(e){S(this).wrapAll(n?t.call(this,e):t)})},unwrap:function(e){return this.parent(e).not("body").each(function(){S(this).replaceWith(this.childNodes)}),this}}),S.expr.pseudos.hidden=function(e){return!S.expr.pseudos.visible(e)},S.expr.pseudos.visible=function(e){return!!(e.offsetWidth||e.offsetHeight||e.getClientRects().length)},S.ajaxSettings.xhr=function(){try{return new C.XMLHttpRequest}catch(e){}};var _t={0:200,1223:204},zt=S.ajaxSettings.xhr();y.cors=!!zt&&"withCredentials"in zt,y.ajax=zt=!!zt,S.ajaxTransport(function(i){var o,a;if(y.cors||zt&&!i.crossDomain)return{send:function(e,t){var n,r=i.xhr();if(r.open(i.type,i.url,i.async,i.username,i.password),i.xhrFields)for(n in i.xhrFields)r[n]=i.xhrFields[n];for(n in i.mimeType&&r.overrideMimeType&&r.overrideMimeType(i.mimeType),i.crossDomain||e["X-Requested-With"]||(e["X-Requested-With"]="XMLHttpRequest"),e)r.setRequestHeader(n,e[n]);o=function(e){return function(){o&&(o=a=r.onload=r.onerror=r.onabort=r.ontimeout=r.onreadystatechange=null,"abort"===e?r.abort():"error"===e?"number"!=typeof r.status?t(0,"error"):t(r.status,r.statusText):t(_t[r.status]||r.status,r.statusText,"text"!==(r.responseType||"text")||"string"!=typeof r.responseText?{binary:r.response}:{text:r.responseText},r.getAllResponseHeaders()))}},r.onload=o(),a=r.onerror=r.ontimeout=o("error"),void 0!==r.onabort?r.onabort=a:r.onreadystatechange=function(){4===r.readyState&&C.setTimeout(function(){o&&a()})},o=o("abort");try{r.send(i.hasContent&&i.data||null)}catch(e){if(o)throw e}},abort:function(){o&&o()}}}),S.ajaxPrefilter(function(e){e.crossDomain&&(e.contents.script=!1)}),S.ajaxSetup({accepts:{script:"text/javascript, application/javascript, application/ecmascript, application/x-ecmascript"},contents:{script:/\b(?:java|ecma)script\b/},converters:{"text script":function(e){return S.globalEval(e),e}}}),S.ajaxPrefilter("script",function(e){void 0===e.cache&&(e.cache=!1),e.crossDomain&&(e.type="GET")}),S.ajaxTransport("script",function(n){var r,i;if(n.crossDomain||n.scriptAttrs)return{send:function(e,t){r=S("<script>").attr(n.scriptAttrs||{}).prop({charset:n.scriptCharset,src:n.url}).on("load error",i=function(e){r.remove(),i=null,e&&t("error"===e.type?404:200,e.type)}),E.head.appendChild(r[0])},abort:function(){i&&i()}}});var Ut,Xt=[],Vt=/(=)\?(?=&|$)|\?\?/;S.ajaxSetup({jsonp:"callback",jsonpCallback:function(){var e=Xt.pop()||S.expando+"_"+Ct.guid++;return this[e]=!0,e}}),S.ajaxPrefilter("json jsonp",function(e,t,n){var r,i,o,a=!1!==e.jsonp&&(Vt.test(e.url)?"url":"string"==typeof e.data&&0===(e.contentType||"").indexOf("application/x-www-form-urlencoded")&&Vt.test(e.data)&&"data");if(a||"jsonp"===e.dataTypes[0])return r=e.jsonpCallback=m(e.jsonpCallback)?e.jsonpCallback():e.jsonpCallback,a?e[a]=e[a].replace(Vt,"$1"+r):!1!==e.jsonp&&(e.url+=(Et.test(e.url)?"&":"?")+e.jsonp+"="+r),e.converters["script json"]=function(){return o||S.error(r+" was not called"),o[0]},e.dataTypes[0]="json",i=C[r],C[r]=function(){o=arguments},n.always(function(){void 0===i?S(C).removeProp(r):C[r]=i,e[r]&&(e.jsonpCallback=t.jsonpCallback,Xt.push(r)),o&&m(i)&&i(o[0]),o=i=void 0}),"script"}),y.createHTMLDocument=((Ut=E.implementation.createHTMLDocument("").body).innerHTML="<form></form><form></form>",2===Ut.childNodes.length),S.parseHTML=function(e,t,n){return"string"!=typeof e?[]:("boolean"==typeof t&&(n=t,t=!1),t||(y.createHTMLDocument?((r=(t=E.implementation.createHTMLDocument("")).createElement("base")).href=E.location.href,t.head.appendChild(r)):t=E),o=!n&&[],(i=N.exec(e))?[t.createElement(i[1])]:(i=xe([e],t,o),o&&o.length&&S(o).remove(),S.merge([],i.childNodes)));var r,i,o},S.fn.load=function(e,t,n){var r,i,o,a=this,s=e.indexOf(" ");return-1<s&&(r=vt(e.slice(s)),e=e.slice(0,s)),m(t)?(n=t,t=void 0):t&&"object"==typeof t&&(i="POST"),0<a.length&&S.ajax({url:e,type:i||"GET",dataType:"html",data:t}).done(function(e){o=arguments,a.html(r?S("<div>").append(S.parseHTML(e)).find(r):e)}).always(n&&function(e,t){a.each(function(){n.apply(this,o||[e.responseText,t,e])})}),this},S.expr.pseudos.animated=function(t){return S.grep(S.timers,function(e){return t===e.elem}).length},S.offset={setOffset:function(e,t,n){var r,i,o,a,s,u,l=S.css(e,"position"),c=S(e),f={};"static"===l&&(e.style.position="relative"),s=c.offset(),o=S.css(e,"top"),u=S.css(e,"left"),("absolute"===l||"fixed"===l)&&-1<(o+u).indexOf("auto")?(a=(r=c.position()).top,i=r.left):(a=parseFloat(o)||0,i=parseFloat(u)||0),m(t)&&(t=t.call(e,n,S.extend({},s))),null!=t.top&&(f.top=t.top-s.top+a),null!=t.left&&(f.left=t.left-s.left+i),"using"in t?t.using.call(e,f):("number"==typeof f.top&&(f.top+="px"),"number"==typeof f.left&&(f.left+="px"),c.css(f))}},S.fn.extend({offset:function(t){if(arguments.length)return void 0===t?this:this.each(function(e){S.offset.setOffset(this,t,e)});var e,n,r=this[0];return r?r.getClientRects().length?(e=r.getBoundingClientRect(),n=r.ownerDocument.defaultView,{top:e.top+n.pageYOffset,left:e.left+n.pageXOffset}):{top:0,left:0}:void 0},position:function(){if(this[0]){var e,t,n,r=this[0],i={top:0,left:0};if("fixed"===S.css(r,"position"))t=r.getBoundingClientRect();else{t=this.offset(),n=r.ownerDocument,e=r.offsetParent||n.documentElement;while(e&&(e===n.body||e===n.documentElement)&&"static"===S.css(e,"position"))e=e.parentNode;e&&e!==r&&1===e.nodeType&&((i=S(e).offset()).top+=S.css(e,"borderTopWidth",!0),i.left+=S.css(e,"borderLeftWidth",!0))}return{top:t.top-i.top-S.css(r,"marginTop",!0),left:t.left-i.left-S.css(r,"marginLeft",!0)}}},offsetParent:function(){return this.map(function(){var e=this.offsetParent;while(e&&"static"===S.css(e,"position"))e=e.offsetParent;return e||re})}}),S.each({scrollLeft:"pageXOffset",scrollTop:"pageYOffset"},function(t,i){var o="pageYOffset"===i;S.fn[t]=function(e){return $(this,function(e,t,n){var r;if(x(e)?r=e:9===e.nodeType&&(r=e.defaultView),void 0===n)return r?r[i]:e[t];r?r.scrollTo(o?r.pageXOffset:n,o?n:r.pageYOffset):e[t]=n},t,e,arguments.length)}}),S.each(["top","left"],function(e,n){S.cssHooks[n]=$e(y.pixelPosition,function(e,t){if(t)return t=Be(e,n),Me.test(t)?S(e).position()[n]+"px":t})}),S.each({Height:"height",Width:"width"},function(a,s){S.each({padding:"inner"+a,content:s,"":"outer"+a},function(r,o){S.fn[o]=function(e,t){var n=arguments.length&&(r||"boolean"!=typeof e),i=r||(!0===e||!0===t?"margin":"border");return $(this,function(e,t,n){var r;return x(e)?0===o.indexOf("outer")?e["inner"+a]:e.document.documentElement["client"+a]:9===e.nodeType?(r=e.documentElement,Math.max(e.body["scroll"+a],r["scroll"+a],e.body["offset"+a],r["offset"+a],r["client"+a])):void 0===n?S.css(e,t,i):S.style(e,t,n,i)},s,n?e:void 0,n)}})}),S.each(["ajaxStart","ajaxStop","ajaxComplete","ajaxError","ajaxSuccess","ajaxSend"],function(e,t){S.fn[t]=function(e){return this.on(t,e)}}),S.fn.extend({bind:function(e,t,n){return this.on(e,null,t,n)},unbind:function(e,t){return this.off(e,null,t)},delegate:function(e,t,n,r){return this.on(t,e,n,r)},undelegate:function(e,t,n){return 1===arguments.length?this.off(e,"**"):this.off(t,e||"**",n)},hover:function(e,t){return this.mouseenter(e).mouseleave(t||e)}}),S.each("blur focus focusin focusout resize scroll click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select submit keydown keypress keyup contextmenu".split(" "),function(e,n){S.fn[n]=function(e,t){return 0<arguments.length?this.on(n,null,e,t):this.trigger(n)}});var Gt=/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g;S.proxy=function(e,t){var n,r,i;if("string"==typeof t&&(n=e[t],t=e,e=n),m(e))return r=s.call(arguments,2),(i=function(){return e.apply(t||this,r.concat(s.call(arguments)))}).guid=e.guid=e.guid||S.guid++,i},S.holdReady=function(e){e?S.readyWait++:S.ready(!0)},S.isArray=Array.isArray,S.parseJSON=JSON.parse,S.nodeName=A,S.isFunction=m,S.isWindow=x,S.camelCase=X,S.type=w,S.now=Date.now,S.isNumeric=function(e){var t=S.type(e);return("number"===t||"string"===t)&&!isNaN(e-parseFloat(e))},S.trim=function(e){return null==e?"":(e+"").replace(Gt,"")},"function"==typeof define&&define.amd&&define("jquery",[],function(){return S});var Yt=C.jQuery,Qt=C.$;return S.noConflict=function(e){return C.$===S&&(C.$=Qt),e&&C.jQuery===S&&(C.jQuery=Yt),S},"undefined"==typeof e&&(C.jQuery=C.$=S),S});

/*!
 * Vue.js v2.6.11
 * (c) 2014-2019 Evan You
 * Released under the MIT License.
 */
!function (e, t) { "object" == typeof exports && "undefined" != typeof module ? module.exports = t() : "function" == typeof define && define.amd ? define(t) : (e = e || self).Vue = t() }(this, function () { "use strict"; var e = Object.freeze({}); function t(e) { return null == e } function n(e) { return null != e } function r(e) { return !0 === e } function i(e) { return "string" == typeof e || "number" == typeof e || "symbol" == typeof e || "boolean" == typeof e } function o(e) { return null !== e && "object" == typeof e } var a = Object.prototype.toString; function s(e) { return "[object Object]" === a.call(e) } function c(e) { var t = parseFloat(String(e)); return t >= 0 && Math.floor(t) === t && isFinite(e) } function u(e) { return n(e) && "function" == typeof e.then && "function" == typeof e.catch } function l(e) { return null == e ? "" : Array.isArray(e) || s(e) && e.toString === a ? JSON.stringify(e, null, 2) : String(e) } function f(e) { var t = parseFloat(e); return isNaN(t) ? e : t } function p(e, t) { for (var n = Object.create(null), r = e.split(","), i = 0; i < r.length; i++)n[r[i]] = !0; return t ? function (e) { return n[e.toLowerCase()] } : function (e) { return n[e] } } var d = p("slot,component", !0), v = p("key,ref,slot,slot-scope,is"); function h(e, t) { if (e.length) { var n = e.indexOf(t); if (n > -1) return e.splice(n, 1) } } var m = Object.prototype.hasOwnProperty; function y(e, t) { return m.call(e, t) } function g(e) { var t = Object.create(null); return function (n) { return t[n] || (t[n] = e(n)) } } var _ = /-(\w)/g, b = g(function (e) { return e.replace(_, function (e, t) { return t ? t.toUpperCase() : "" }) }), $ = g(function (e) { return e.charAt(0).toUpperCase() + e.slice(1) }), w = /\B([A-Z])/g, C = g(function (e) { return e.replace(w, "-$1").toLowerCase() }); var x = Function.prototype.bind ? function (e, t) { return e.bind(t) } : function (e, t) { function n(n) { var r = arguments.length; return r ? r > 1 ? e.apply(t, arguments) : e.call(t, n) : e.call(t) } return n._length = e.length, n }; function k(e, t) { t = t || 0; for (var n = e.length - t, r = new Array(n); n--;)r[n] = e[n + t]; return r } function A(e, t) { for (var n in t) e[n] = t[n]; return e } function O(e) { for (var t = {}, n = 0; n < e.length; n++)e[n] && A(t, e[n]); return t } function S(e, t, n) { } var T = function (e, t, n) { return !1 }, E = function (e) { return e }; function N(e, t) { if (e === t) return !0; var n = o(e), r = o(t); if (!n || !r) return !n && !r && String(e) === String(t); try { var i = Array.isArray(e), a = Array.isArray(t); if (i && a) return e.length === t.length && e.every(function (e, n) { return N(e, t[n]) }); if (e instanceof Date && t instanceof Date) return e.getTime() === t.getTime(); if (i || a) return !1; var s = Object.keys(e), c = Object.keys(t); return s.length === c.length && s.every(function (n) { return N(e[n], t[n]) }) } catch (e) { return !1 } } function j(e, t) { for (var n = 0; n < e.length; n++)if (N(e[n], t)) return n; return -1 } function D(e) { var t = !1; return function () { t || (t = !0, e.apply(this, arguments)) } } var L = "data-server-rendered", M = ["component", "directive", "filter"], I = ["beforeCreate", "created", "beforeMount", "mounted", "beforeUpdate", "updated", "beforeDestroy", "destroyed", "activated", "deactivated", "errorCaptured", "serverPrefetch"], F = { optionMergeStrategies: Object.create(null), silent: !1, productionTip: !1, devtools: !1, performance: !1, errorHandler: null, warnHandler: null, ignoredElements: [], keyCodes: Object.create(null), isReservedTag: T, isReservedAttr: T, isUnknownElement: T, getTagNamespace: S, parsePlatformTagName: E, mustUseProp: T, async: !0, _lifecycleHooks: I }, P = /a-zA-Z\u00B7\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u037D\u037F-\u1FFF\u200C-\u200D\u203F-\u2040\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD/; function R(e, t, n, r) { Object.defineProperty(e, t, { value: n, enumerable: !!r, writable: !0, configurable: !0 }) } var H = new RegExp("[^" + P.source + ".$_\\d]"); var B, U = "__proto__" in {}, z = "undefined" != typeof window, V = "undefined" != typeof WXEnvironment && !!WXEnvironment.platform, K = V && WXEnvironment.platform.toLowerCase(), J = z && window.navigator.userAgent.toLowerCase(), q = J && /msie|trident/.test(J), W = J && J.indexOf("msie 9.0") > 0, Z = J && J.indexOf("edge/") > 0, G = (J && J.indexOf("android"), J && /iphone|ipad|ipod|ios/.test(J) || "ios" === K), X = (J && /chrome\/\d+/.test(J), J && /phantomjs/.test(J), J && J.match(/firefox\/(\d+)/)), Y = {}.watch, Q = !1; if (z) try { var ee = {}; Object.defineProperty(ee, "passive", { get: function () { Q = !0 } }), window.addEventListener("test-passive", null, ee) } catch (e) { } var te = function () { return void 0 === B && (B = !z && !V && "undefined" != typeof global && (global.process && "server" === global.process.env.VUE_ENV)), B }, ne = z && window.__VUE_DEVTOOLS_GLOBAL_HOOK__; function re(e) { return "function" == typeof e && /native code/.test(e.toString()) } var ie, oe = "undefined" != typeof Symbol && re(Symbol) && "undefined" != typeof Reflect && re(Reflect.ownKeys); ie = "undefined" != typeof Set && re(Set) ? Set : function () { function e() { this.set = Object.create(null) } return e.prototype.has = function (e) { return !0 === this.set[e] }, e.prototype.add = function (e) { this.set[e] = !0 }, e.prototype.clear = function () { this.set = Object.create(null) }, e }(); var ae = S, se = 0, ce = function () { this.id = se++, this.subs = [] }; ce.prototype.addSub = function (e) { this.subs.push(e) }, ce.prototype.removeSub = function (e) { h(this.subs, e) }, ce.prototype.depend = function () { ce.target && ce.target.addDep(this) }, ce.prototype.notify = function () { for (var e = this.subs.slice(), t = 0, n = e.length; t < n; t++)e[t].update() }, ce.target = null; var ue = []; function le(e) { ue.push(e), ce.target = e } function fe() { ue.pop(), ce.target = ue[ue.length - 1] } var pe = function (e, t, n, r, i, o, a, s) { this.tag = e, this.data = t, this.children = n, this.text = r, this.elm = i, this.ns = void 0, this.context = o, this.fnContext = void 0, this.fnOptions = void 0, this.fnScopeId = void 0, this.key = t && t.key, this.componentOptions = a, this.componentInstance = void 0, this.parent = void 0, this.raw = !1, this.isStatic = !1, this.isRootInsert = !0, this.isComment = !1, this.isCloned = !1, this.isOnce = !1, this.asyncFactory = s, this.asyncMeta = void 0, this.isAsyncPlaceholder = !1 }, de = { child: { configurable: !0 } }; de.child.get = function () { return this.componentInstance }, Object.defineProperties(pe.prototype, de); var ve = function (e) { void 0 === e && (e = ""); var t = new pe; return t.text = e, t.isComment = !0, t }; function he(e) { return new pe(void 0, void 0, void 0, String(e)) } function me(e) { var t = new pe(e.tag, e.data, e.children && e.children.slice(), e.text, e.elm, e.context, e.componentOptions, e.asyncFactory); return t.ns = e.ns, t.isStatic = e.isStatic, t.key = e.key, t.isComment = e.isComment, t.fnContext = e.fnContext, t.fnOptions = e.fnOptions, t.fnScopeId = e.fnScopeId, t.asyncMeta = e.asyncMeta, t.isCloned = !0, t } var ye = Array.prototype, ge = Object.create(ye);["push", "pop", "shift", "unshift", "splice", "sort", "reverse"].forEach(function (e) { var t = ye[e]; R(ge, e, function () { for (var n = [], r = arguments.length; r--;)n[r] = arguments[r]; var i, o = t.apply(this, n), a = this.__ob__; switch (e) { case "push": case "unshift": i = n; break; case "splice": i = n.slice(2) }return i && a.observeArray(i), a.dep.notify(), o }) }); var _e = Object.getOwnPropertyNames(ge), be = !0; function $e(e) { be = e } var we = function (e) { var t; this.value = e, this.dep = new ce, this.vmCount = 0, R(e, "__ob__", this), Array.isArray(e) ? (U ? (t = ge, e.__proto__ = t) : function (e, t, n) { for (var r = 0, i = n.length; r < i; r++) { var o = n[r]; R(e, o, t[o]) } }(e, ge, _e), this.observeArray(e)) : this.walk(e) }; function Ce(e, t) { var n; if (o(e) && !(e instanceof pe)) return y(e, "__ob__") && e.__ob__ instanceof we ? n = e.__ob__ : be && !te() && (Array.isArray(e) || s(e)) && Object.isExtensible(e) && !e._isVue && (n = new we(e)), t && n && n.vmCount++, n } function xe(e, t, n, r, i) { var o = new ce, a = Object.getOwnPropertyDescriptor(e, t); if (!a || !1 !== a.configurable) { var s = a && a.get, c = a && a.set; s && !c || 2 !== arguments.length || (n = e[t]); var u = !i && Ce(n); Object.defineProperty(e, t, { enumerable: !0, configurable: !0, get: function () { var t = s ? s.call(e) : n; return ce.target && (o.depend(), u && (u.dep.depend(), Array.isArray(t) && function e(t) { for (var n = void 0, r = 0, i = t.length; r < i; r++)(n = t[r]) && n.__ob__ && n.__ob__.dep.depend(), Array.isArray(n) && e(n) }(t))), t }, set: function (t) { var r = s ? s.call(e) : n; t === r || t != t && r != r || s && !c || (c ? c.call(e, t) : n = t, u = !i && Ce(t), o.notify()) } }) } } function ke(e, t, n) { if (Array.isArray(e) && c(t)) return e.length = Math.max(e.length, t), e.splice(t, 1, n), n; if (t in e && !(t in Object.prototype)) return e[t] = n, n; var r = e.__ob__; return e._isVue || r && r.vmCount ? n : r ? (xe(r.value, t, n), r.dep.notify(), n) : (e[t] = n, n) } function Ae(e, t) { if (Array.isArray(e) && c(t)) e.splice(t, 1); else { var n = e.__ob__; e._isVue || n && n.vmCount || y(e, t) && (delete e[t], n && n.dep.notify()) } } we.prototype.walk = function (e) { for (var t = Object.keys(e), n = 0; n < t.length; n++)xe(e, t[n]) }, we.prototype.observeArray = function (e) { for (var t = 0, n = e.length; t < n; t++)Ce(e[t]) }; var Oe = F.optionMergeStrategies; function Se(e, t) { if (!t) return e; for (var n, r, i, o = oe ? Reflect.ownKeys(t) : Object.keys(t), a = 0; a < o.length; a++)"__ob__" !== (n = o[a]) && (r = e[n], i = t[n], y(e, n) ? r !== i && s(r) && s(i) && Se(r, i) : ke(e, n, i)); return e } function Te(e, t, n) { return n ? function () { var r = "function" == typeof t ? t.call(n, n) : t, i = "function" == typeof e ? e.call(n, n) : e; return r ? Se(r, i) : i } : t ? e ? function () { return Se("function" == typeof t ? t.call(this, this) : t, "function" == typeof e ? e.call(this, this) : e) } : t : e } function Ee(e, t) { var n = t ? e ? e.concat(t) : Array.isArray(t) ? t : [t] : e; return n ? function (e) { for (var t = [], n = 0; n < e.length; n++)-1 === t.indexOf(e[n]) && t.push(e[n]); return t }(n) : n } function Ne(e, t, n, r) { var i = Object.create(e || null); return t ? A(i, t) : i } Oe.data = function (e, t, n) { return n ? Te(e, t, n) : t && "function" != typeof t ? e : Te(e, t) }, I.forEach(function (e) { Oe[e] = Ee }), M.forEach(function (e) { Oe[e + "s"] = Ne }), Oe.watch = function (e, t, n, r) { if (e === Y && (e = void 0), t === Y && (t = void 0), !t) return Object.create(e || null); if (!e) return t; var i = {}; for (var o in A(i, e), t) { var a = i[o], s = t[o]; a && !Array.isArray(a) && (a = [a]), i[o] = a ? a.concat(s) : Array.isArray(s) ? s : [s] } return i }, Oe.props = Oe.methods = Oe.inject = Oe.computed = function (e, t, n, r) { if (!e) return t; var i = Object.create(null); return A(i, e), t && A(i, t), i }, Oe.provide = Te; var je = function (e, t) { return void 0 === t ? e : t }; function De(e, t, n) { if ("function" == typeof t && (t = t.options), function (e, t) { var n = e.props; if (n) { var r, i, o = {}; if (Array.isArray(n)) for (r = n.length; r--;)"string" == typeof (i = n[r]) && (o[b(i)] = { type: null }); else if (s(n)) for (var a in n) i = n[a], o[b(a)] = s(i) ? i : { type: i }; e.props = o } }(t), function (e, t) { var n = e.inject; if (n) { var r = e.inject = {}; if (Array.isArray(n)) for (var i = 0; i < n.length; i++)r[n[i]] = { from: n[i] }; else if (s(n)) for (var o in n) { var a = n[o]; r[o] = s(a) ? A({ from: o }, a) : { from: a } } } }(t), function (e) { var t = e.directives; if (t) for (var n in t) { var r = t[n]; "function" == typeof r && (t[n] = { bind: r, update: r }) } }(t), !t._base && (t.extends && (e = De(e, t.extends, n)), t.mixins)) for (var r = 0, i = t.mixins.length; r < i; r++)e = De(e, t.mixins[r], n); var o, a = {}; for (o in e) c(o); for (o in t) y(e, o) || c(o); function c(r) { var i = Oe[r] || je; a[r] = i(e[r], t[r], n, r) } return a } function Le(e, t, n, r) { if ("string" == typeof n) { var i = e[t]; if (y(i, n)) return i[n]; var o = b(n); if (y(i, o)) return i[o]; var a = $(o); return y(i, a) ? i[a] : i[n] || i[o] || i[a] } } function Me(e, t, n, r) { var i = t[e], o = !y(n, e), a = n[e], s = Pe(Boolean, i.type); if (s > -1) if (o && !y(i, "default")) a = !1; else if ("" === a || a === C(e)) { var c = Pe(String, i.type); (c < 0 || s < c) && (a = !0) } if (void 0 === a) { a = function (e, t, n) { if (!y(t, "default")) return; var r = t.default; if (e && e.$options.propsData && void 0 === e.$options.propsData[n] && void 0 !== e._props[n]) return e._props[n]; return "function" == typeof r && "Function" !== Ie(t.type) ? r.call(e) : r }(r, i, e); var u = be; $e(!0), Ce(a), $e(u) } return a } function Ie(e) { var t = e && e.toString().match(/^\s*function (\w+)/); return t ? t[1] : "" } function Fe(e, t) { return Ie(e) === Ie(t) } function Pe(e, t) { if (!Array.isArray(t)) return Fe(t, e) ? 0 : -1; for (var n = 0, r = t.length; n < r; n++)if (Fe(t[n], e)) return n; return -1 } function Re(e, t, n) { le(); try { if (t) for (var r = t; r = r.$parent;) { var i = r.$options.errorCaptured; if (i) for (var o = 0; o < i.length; o++)try { if (!1 === i[o].call(r, e, t, n)) return } catch (e) { Be(e, r, "errorCaptured hook") } } Be(e, t, n) } finally { fe() } } function He(e, t, n, r, i) { var o; try { (o = n ? e.apply(t, n) : e.call(t)) && !o._isVue && u(o) && !o._handled && (o.catch(function (e) { return Re(e, r, i + " (Promise/async)") }), o._handled = !0) } catch (e) { Re(e, r, i) } return o } function Be(e, t, n) { if (F.errorHandler) try { return F.errorHandler.call(null, e, t, n) } catch (t) { t !== e && Ue(t, null, "config.errorHandler") } Ue(e, t, n) } function Ue(e, t, n) { console.error('Ue func error'); } var ze, Ve = !1, Ke = [], Je = !1; function qe() { Je = !1; var e = Ke.slice(0); Ke.length = 0; for (var t = 0; t < e.length; t++)e[t]() } if ("undefined" != typeof Promise && re(Promise)) { var We = Promise.resolve(); ze = function () { We.then(qe), G && setTimeout(S) }, Ve = !0 } else if (q || "undefined" == typeof MutationObserver || !re(MutationObserver) && "[object MutationObserverConstructor]" !== MutationObserver.toString()) ze = "undefined" != typeof setImmediate && re(setImmediate) ? function () { setImmediate(qe) } : function () { setTimeout(qe, 0) }; else { var Ze = 1, Ge = new MutationObserver(qe), Xe = document.createTextNode(String(Ze)); Ge.observe(Xe, { characterData: !0 }), ze = function () { Ze = (Ze + 1) % 2, Xe.data = String(Ze) }, Ve = !0 } function Ye(e, t) { var n; if (Ke.push(function () { if (e) try { e.call(t) } catch (e) { Re(e, t, "nextTick") } else n && n(t) }), Je || (Je = !0, ze()), !e && "undefined" != typeof Promise) return new Promise(function (e) { n = e }) } var Qe = new ie; function et(e) { !function e(t, n) { var r, i; var a = Array.isArray(t); if (!a && !o(t) || Object.isFrozen(t) || t instanceof pe) return; if (t.__ob__) { var s = t.__ob__.dep.id; if (n.has(s)) return; n.add(s) } if (a) for (r = t.length; r--;)e(t[r], n); else for (i = Object.keys(t), r = i.length; r--;)e(t[i[r]], n) }(e, Qe), Qe.clear() } var tt = g(function (e) { var t = "&" === e.charAt(0), n = "~" === (e = t ? e.slice(1) : e).charAt(0), r = "!" === (e = n ? e.slice(1) : e).charAt(0); return { name: e = r ? e.slice(1) : e, once: n, capture: r, passive: t } }); function nt(e, t) { function n() { var e = arguments, r = n.fns; if (!Array.isArray(r)) return He(r, null, arguments, t, "v-on handler"); for (var i = r.slice(), o = 0; o < i.length; o++)He(i[o], null, e, t, "v-on handler") } return n.fns = e, n } function rt(e, n, i, o, a, s) { var c, u, l, f; for (c in e) u = e[c], l = n[c], f = tt(c), t(u) || (t(l) ? (t(u.fns) && (u = e[c] = nt(u, s)), r(f.once) && (u = e[c] = a(f.name, u, f.capture)), i(f.name, u, f.capture, f.passive, f.params)) : u !== l && (l.fns = u, e[c] = l)); for (c in n) t(e[c]) && o((f = tt(c)).name, n[c], f.capture) } function it(e, i, o) { var a; e instanceof pe && (e = e.data.hook || (e.data.hook = {})); var s = e[i]; function c() { o.apply(this, arguments), h(a.fns, c) } t(s) ? a = nt([c]) : n(s.fns) && r(s.merged) ? (a = s).fns.push(c) : a = nt([s, c]), a.merged = !0, e[i] = a } function ot(e, t, r, i, o) { if (n(t)) { if (y(t, r)) return e[r] = t[r], o || delete t[r], !0; if (y(t, i)) return e[r] = t[i], o || delete t[i], !0 } return !1 } function at(e) { return i(e) ? [he(e)] : Array.isArray(e) ? function e(o, a) { var s = []; var c, u, l, f; for (c = 0; c < o.length; c++)t(u = o[c]) || "boolean" == typeof u || (l = s.length - 1, f = s[l], Array.isArray(u) ? u.length > 0 && (st((u = e(u, (a || "") + "_" + c))[0]) && st(f) && (s[l] = he(f.text + u[0].text), u.shift()), s.push.apply(s, u)) : i(u) ? st(f) ? s[l] = he(f.text + u) : "" !== u && s.push(he(u)) : st(u) && st(f) ? s[l] = he(f.text + u.text) : (r(o._isVList) && n(u.tag) && t(u.key) && n(a) && (u.key = "__vlist" + a + "_" + c + "__"), s.push(u))); return s }(e) : void 0 } function st(e) { return n(e) && n(e.text) && !1 === e.isComment } function ct(e, t) { if (e) { for (var n = Object.create(null), r = oe ? Reflect.ownKeys(e) : Object.keys(e), i = 0; i < r.length; i++){ var o = r[i]; if ("__ob__" !== o) { for (var a = e[o].from, s = t; s;){ if (s._provided && y(s._provided, a)) { n[o] = s._provided[a]; break } s = s.$parent } if (!s && "default" in e[o]) { var c = e[o].default; n[o] = "function" == typeof c ? c.call(t) : c } } } return n } } function ut(e, t) { if (!e || !e.length) return {}; for (var n = {}, r = 0, i = e.length; r < i; r++){ var o = e[r], a = o.data; if (a && a.attrs && a.attrs.slot && delete a.attrs.slot, o.context !== t && o.fnContext !== t || !a || null == a.slot) (n.default || (n.default = [])).push(o); else { var s = a.slot, c = n[s] || (n[s] = []); "template" === o.tag ? c.push.apply(c, o.children || []) : c.push(o) } } for (var u in n) n[u].every(lt) && delete n[u]; return n } function lt(e) { return e.isComment && !e.asyncFactory || " " === e.text } function ft(t, n, r) { var i, o = Object.keys(n).length > 0, a = t ? !!t.$stable : !o, s = t && t.$key; if (t) { if (t._normalized) return t._normalized; if (a && r && r !== e && s === r.$key && !o && !r.$hasNormal) return r; for (var c in i = {}, t) t[c] && "$" !== c[0] && (i[c] = pt(n, c, t[c])) } else i = {}; for (var u in n) u in i || (i[u] = dt(n, u)); return t && Object.isExtensible(t) && (t._normalized = i), R(i, "$stable", a), R(i, "$key", s), R(i, "$hasNormal", o), i } function pt(e, t, n) { var r = function () { var e = arguments.length ? n.apply(null, arguments) : n({}); return (e = e && "object" == typeof e && !Array.isArray(e) ? [e] : at(e)) && (0 === e.length || 1 === e.length && e[0].isComment) ? void 0 : e }; return n.proxy && Object.defineProperty(e, t, { get: r, enumerable: !0, configurable: !0 }), r } function dt(e, t) { return function () { return e[t] } } function vt(e, t) { var r, i, a, s, c; if (Array.isArray(e) || "string" == typeof e) for (r = new Array(e.length), i = 0, a = e.length; i < a; i++)r[i] = t(e[i], i); else if ("number" == typeof e) for (r = new Array(e), i = 0; i < e; i++)r[i] = t(i + 1, i); else if (o(e)) if (oe && e[Symbol.iterator]) { r = []; for (var u = e[Symbol.iterator](), l = u.next(); !l.done;)r.push(t(l.value, r.length)), l = u.next() } else for (s = Object.keys(e), r = new Array(s.length), i = 0, a = s.length; i < a; i++)c = s[i], r[i] = t(e[c], c, i); return n(r) || (r = []), r._isVList = !0, r } function ht(e, t, n, r) { var i, o = this.$scopedSlots[e]; o ? (n = n || {}, r && (n = A(A({}, r), n)), i = o(n) || t) : i = this.$slots[e] || t; var a = n && n.slot; return a ? this.$createElement("template", { slot: a }, i) : i } function mt(e) { return Le(this.$options, "filters", e) || E } function yt(e, t) { return Array.isArray(e) ? -1 === e.indexOf(t) : e !== t } function gt(e, t, n, r, i) { var o = F.keyCodes[t] || n; return i && r && !F.keyCodes[t] ? yt(i, r) : o ? yt(o, e) : r ? C(r) !== t : void 0 } function _t(e, t, n, r, i) { if (n) if (o(n)) { var a; Array.isArray(n) && (n = O(n)); var s = function (o) { if ("class" === o || "style" === o || v(o)) a = e; else { var s = e.attrs && e.attrs.type; a = r || F.mustUseProp(t, s, o) ? e.domProps || (e.domProps = {}) : e.attrs || (e.attrs = {}) } var c = b(o), u = C(o); c in a || u in a || (a[o] = n[o], i && ((e.on || (e.on = {}))["update:" + o] = function (e) { n[o] = e })) }; for (var c in n) s(c) } else; return e } function bt(e, t) { var n = this._staticTrees || (this._staticTrees = []), r = n[e]; return r && !t ? r : (wt(r = n[e] = this.$options.staticRenderFns[e].call(this._renderProxy, null, this), "__static__" + e, !1), r) } function $t(e, t, n) { return wt(e, "__once__" + t + (n ? "_" + n : ""), !0), e } function wt(e, t, n) { if (Array.isArray(e)) for (var r = 0; r < e.length; r++)e[r] && "string" != typeof e[r] && Ct(e[r], t + "_" + r, n); else Ct(e, t, n) } function Ct(e, t, n) { e.isStatic = !0, e.key = t, e.isOnce = n } function xt(e, t) { if (t) if (s(t)) { var n = e.on = e.on ? A({}, e.on) : {}; for (var r in t) { var i = n[r], o = t[r]; n[r] = i ? [].concat(i, o) : o } } else; return e } function kt(e, t, n, r) { t = t || { $stable: !n }; for (var i = 0; i < e.length; i++){ var o = e[i]; Array.isArray(o) ? kt(o, t, n) : o && (o.proxy && (o.fn.proxy = !0), t[o.key] = o.fn) } return r && (t.$key = r), t } function At(e, t) { for (var n = 0; n < t.length; n += 2){ var r = t[n]; "string" == typeof r && r && (e[t[n]] = t[n + 1]) } return e } function Ot(e, t) { return "string" == typeof e ? t + e : e } function St(e) { e._o = $t, e._n = f, e._s = l, e._l = vt, e._t = ht, e._q = N, e._i = j, e._m = bt, e._f = mt, e._k = gt, e._b = _t, e._v = he, e._e = ve, e._u = kt, e._g = xt, e._d = At, e._p = Ot } function Tt(t, n, i, o, a) { var s, c = this, u = a.options; y(o, "_uid") ? (s = Object.create(o))._original = o : (s = o, o = o._original); var l = r(u._compiled), f = !l; this.data = t, this.props = n, this.children = i, this.parent = o, this.listeners = t.on || e, this.injections = ct(u.inject, o), this.slots = function () { return c.$slots || ft(t.scopedSlots, c.$slots = ut(i, o)), c.$slots }, Object.defineProperty(this, "scopedSlots", { enumerable: !0, get: function () { return ft(t.scopedSlots, this.slots()) } }), l && (this.$options = u, this.$slots = this.slots(), this.$scopedSlots = ft(t.scopedSlots, this.$slots)), u._scopeId ? this._c = function (e, t, n, r) { var i = Pt(s, e, t, n, r, f); return i && !Array.isArray(i) && (i.fnScopeId = u._scopeId, i.fnContext = o), i } : this._c = function (e, t, n, r) { return Pt(s, e, t, n, r, f) } } function Et(e, t, n, r, i) { var o = me(e); return o.fnContext = n, o.fnOptions = r, t.slot && ((o.data || (o.data = {})).slot = t.slot), o } function Nt(e, t) { for (var n in t) e[b(n)] = t[n] } St(Tt.prototype); var jt = { init: function (e, t) { if (e.componentInstance && !e.componentInstance._isDestroyed && e.data.keepAlive) { var r = e; jt.prepatch(r, r) } else { (e.componentInstance = function (e, t) { var r = { _isComponent: !0, _parentVnode: e, parent: t }, i = e.data.inlineTemplate; n(i) && (r.render = i.render, r.staticRenderFns = i.staticRenderFns); return new e.componentOptions.Ctor(r) }(e, Wt)).$mount(t ? e.elm : void 0, t) } }, prepatch: function (t, n) { var r = n.componentOptions; !function (t, n, r, i, o) { var a = i.data.scopedSlots, s = t.$scopedSlots, c = !!(a && !a.$stable || s !== e && !s.$stable || a && t.$scopedSlots.$key !== a.$key), u = !!(o || t.$options._renderChildren || c); t.$options._parentVnode = i, t.$vnode = i, t._vnode && (t._vnode.parent = i); if (t.$options._renderChildren = o, t.$attrs = i.data.attrs || e, t.$listeners = r || e, n && t.$options.props) { $e(!1); for (var l = t._props, f = t.$options._propKeys || [], p = 0; p < f.length; p++){ var d = f[p], v = t.$options.props; l[d] = Me(d, v, n, t) } $e(!0), t.$options.propsData = n } r = r || e; var h = t.$options._parentListeners; t.$options._parentListeners = r, qt(t, r, h), u && (t.$slots = ut(o, i.context), t.$forceUpdate()) }(n.componentInstance = t.componentInstance, r.propsData, r.listeners, n, r.children) }, insert: function (e) { var t, n = e.context, r = e.componentInstance; r._isMounted || (r._isMounted = !0, Yt(r, "mounted")), e.data.keepAlive && (n._isMounted ? ((t = r)._inactive = !1, en.push(t)) : Xt(r, !0)) }, destroy: function (e) { var t = e.componentInstance; t._isDestroyed || (e.data.keepAlive ? function e(t, n) { if (n && (t._directInactive = !0, Gt(t))) return; if (!t._inactive) { t._inactive = !0; for (var r = 0; r < t.$children.length; r++)e(t.$children[r]); Yt(t, "deactivated") } }(t, !0) : t.$destroy()) } }, Dt = Object.keys(jt); function Lt(i, a, s, c, l) { if (!t(i)) { var f = s.$options._base; if (o(i) && (i = f.extend(i)), "function" == typeof i) { var p; if (t(i.cid) && void 0 === (i = function (e, i) { if (r(e.error) && n(e.errorComp)) return e.errorComp; if (n(e.resolved)) return e.resolved; var a = Ht; a && n(e.owners) && -1 === e.owners.indexOf(a) && e.owners.push(a); if (r(e.loading) && n(e.loadingComp)) return e.loadingComp; if (a && !n(e.owners)) { var s = e.owners = [a], c = !0, l = null, f = null; a.$on("hook:destroyed", function () { return h(s, a) }); var p = function (e) { for (var t = 0, n = s.length; t < n; t++)s[t].$forceUpdate(); e && (s.length = 0, null !== l && (clearTimeout(l), l = null), null !== f && (clearTimeout(f), f = null)) }, d = D(function (t) { e.resolved = Bt(t, i), c ? s.length = 0 : p(!0) }), v = D(function (t) { n(e.errorComp) && (e.error = !0, p(!0)) }), m = e(d, v); return o(m) && (u(m) ? t(e.resolved) && m.then(d, v) : u(m.component) && (m.component.then(d, v), n(m.error) && (e.errorComp = Bt(m.error, i)), n(m.loading) && (e.loadingComp = Bt(m.loading, i), 0 === m.delay ? e.loading = !0 : l = setTimeout(function () { l = null, t(e.resolved) && t(e.error) && (e.loading = !0, p(!1)) }, m.delay || 200)), n(m.timeout) && (f = setTimeout(function () { f = null, t(e.resolved) && v(null) }, m.timeout)))), c = !1, e.loading ? e.loadingComp : e.resolved } }(p = i, f))) return function (e, t, n, r, i) { var o = ve(); return o.asyncFactory = e, o.asyncMeta = { data: t, context: n, children: r, tag: i }, o }(p, a, s, c, l); a = a || {}, $n(i), n(a.model) && function (e, t) { var r = e.model && e.model.prop || "value", i = e.model && e.model.event || "input"; (t.attrs || (t.attrs = {}))[r] = t.model.value; var o = t.on || (t.on = {}), a = o[i], s = t.model.callback; n(a) ? (Array.isArray(a) ? -1 === a.indexOf(s) : a !== s) && (o[i] = [s].concat(a)) : o[i] = s }(i.options, a); var d = function (e, r, i) { var o = r.options.props; if (!t(o)) { var a = {}, s = e.attrs, c = e.props; if (n(s) || n(c)) for (var u in o) { var l = C(u); ot(a, c, u, l, !0) || ot(a, s, u, l, !1) } return a } }(a, i); if (r(i.options.functional)) return function (t, r, i, o, a) { var s = t.options, c = {}, u = s.props; if (n(u)) for (var l in u) c[l] = Me(l, u, r || e); else n(i.attrs) && Nt(c, i.attrs), n(i.props) && Nt(c, i.props); var f = new Tt(i, c, a, o, t), p = s.render.call(null, f._c, f); if (p instanceof pe) return Et(p, i, f.parent, s); if (Array.isArray(p)) { for (var d = at(p) || [], v = new Array(d.length), h = 0; h < d.length; h++)v[h] = Et(d[h], i, f.parent, s); return v } }(i, d, a, s, c); var v = a.on; if (a.on = a.nativeOn, r(i.options.abstract)) { var m = a.slot; a = {}, m && (a.slot = m) } !function (e) { for (var t = e.hook || (e.hook = {}), n = 0; n < Dt.length; n++){ var r = Dt[n], i = t[r], o = jt[r]; i === o || i && i._merged || (t[r] = i ? Mt(o, i) : o) } }(a); var y = i.options.name || l; return new pe("vue-component-" + i.cid + (y ? "-" + y : ""), a, void 0, void 0, void 0, s, { Ctor: i, propsData: d, listeners: v, tag: l, children: c }, p) } } } function Mt(e, t) { var n = function (n, r) { e(n, r), t(n, r) }; return n._merged = !0, n } var It = 1, Ft = 2; function Pt(e, a, s, c, u, l) { return (Array.isArray(s) || i(s)) && (u = c, c = s, s = void 0), r(l) && (u = Ft), function (e, i, a, s, c) { if (n(a) && n(a.__ob__)) return ve(); n(a) && n(a.is) && (i = a.is); if (!i) return ve(); Array.isArray(s) && "function" == typeof s[0] && ((a = a || {}).scopedSlots = { default: s[0] }, s.length = 0); c === Ft ? s = at(s) : c === It && (s = function (e) { for (var t = 0; t < e.length; t++)if (Array.isArray(e[t])) return Array.prototype.concat.apply([], e); return e }(s)); var u, l; if ("string" == typeof i) { var f; l = e.$vnode && e.$vnode.ns || F.getTagNamespace(i), u = F.isReservedTag(i) ? new pe(F.parsePlatformTagName(i), a, s, void 0, void 0, e) : a && a.pre || !n(f = Le(e.$options, "components", i)) ? new pe(i, a, s, void 0, void 0, e) : Lt(f, a, e, s, i) } else u = Lt(i, a, e, s); return Array.isArray(u) ? u : n(u) ? (n(l) && function e(i, o, a) { i.ns = o; "foreignObject" === i.tag && (o = void 0, a = !0); if (n(i.children)) for (var s = 0, c = i.children.length; s < c; s++){ var u = i.children[s]; n(u.tag) && (t(u.ns) || r(a) && "svg" !== u.tag) && e(u, o, a) } }(u, l), n(a) && function (e) { o(e.style) && et(e.style); o(e.class) && et(e.class) }(a), u) : ve() }(e, a, s, c, u) } var Rt, Ht = null; function Bt(e, t) { return (e.__esModule || oe && "Module" === e[Symbol.toStringTag]) && (e = e.default), o(e) ? t.extend(e) : e } function Ut(e) { return e.isComment && e.asyncFactory } function zt(e) { if (Array.isArray(e)) for (var t = 0; t < e.length; t++){ var r = e[t]; if (n(r) && (n(r.componentOptions) || Ut(r))) return r } } function Vt(e, t) { Rt.$on(e, t) } function Kt(e, t) { Rt.$off(e, t) } function Jt(e, t) { var n = Rt; return function r() { null !== t.apply(null, arguments) && n.$off(e, r) } } function qt(e, t, n) { Rt = e, rt(t, n || {}, Vt, Kt, Jt, e), Rt = void 0 } var Wt = null; function Zt(e) { var t = Wt; return Wt = e, function () { Wt = t } } function Gt(e) { for (; e && (e = e.$parent);)if (e._inactive) return !0; return !1 } function Xt(e, t) { if (t) { if (e._directInactive = !1, Gt(e)) return } else if (e._directInactive) return; if (e._inactive || null === e._inactive) { e._inactive = !1; for (var n = 0; n < e.$children.length; n++)Xt(e.$children[n]); Yt(e, "activated") } } function Yt(e, t) { le(); var n = e.$options[t], r = t + " hook"; if (n) for (var i = 0, o = n.length; i < o; i++)He(n[i], e, null, e, r); e._hasHookEvent && e.$emit("hook:" + t), fe() } var Qt = [], en = [], tn = {}, nn = !1, rn = !1, on = 0; var an = 0, sn = Date.now; if (z && !q) { var cn = window.performance; cn && "function" == typeof cn.now && sn() > document.createEvent("Event").timeStamp && (sn = function () { return cn.now() }) } function un() { var e, t; for (an = sn(), rn = !0, Qt.sort(function (e, t) { return e.id - t.id }), on = 0; on < Qt.length; on++)(e = Qt[on]).before && e.before(), t = e.id, tn[t] = null, e.run(); var n = en.slice(), r = Qt.slice(); on = Qt.length = en.length = 0, tn = {}, nn = rn = !1, function (e) { for (var t = 0; t < e.length; t++)e[t]._inactive = !0, Xt(e[t], !0) }(n), function (e) { var t = e.length; for (; t--;){ var n = e[t], r = n.vm; r._watcher === n && r._isMounted && !r._isDestroyed && Yt(r, "updated") } }(r), ne && F.devtools && ne.emit("flush") } var ln = 0, fn = function (e, t, n, r, i) { this.vm = e, i && (e._watcher = this), e._watchers.push(this), r ? (this.deep = !!r.deep, this.user = !!r.user, this.lazy = !!r.lazy, this.sync = !!r.sync, this.before = r.before) : this.deep = this.user = this.lazy = this.sync = !1, this.cb = n, this.id = ++ln, this.active = !0, this.dirty = this.lazy, this.deps = [], this.newDeps = [], this.depIds = new ie, this.newDepIds = new ie, this.expression = "", "function" == typeof t ? this.getter = t : (this.getter = function (e) { if (!H.test(e)) { var t = e.split("."); return function (e) { for (var n = 0; n < t.length; n++){ if (!e) return; e = e[t[n]] } return e } } }(t), this.getter || (this.getter = S)), this.value = this.lazy ? void 0 : this.get() }; fn.prototype.get = function () { var e; le(this); var t = this.vm; try { e = this.getter.call(t, t) } catch (e) { if (!this.user) throw e; Re(e, t, 'getter for watcher "' + this.expression + '"') } finally { this.deep && et(e), fe(), this.cleanupDeps() } return e }, fn.prototype.addDep = function (e) { var t = e.id; this.newDepIds.has(t) || (this.newDepIds.add(t), this.newDeps.push(e), this.depIds.has(t) || e.addSub(this)) }, fn.prototype.cleanupDeps = function () { for (var e = this.deps.length; e--;){ var t = this.deps[e]; this.newDepIds.has(t.id) || t.removeSub(this) } var n = this.depIds; this.depIds = this.newDepIds, this.newDepIds = n, this.newDepIds.clear(), n = this.deps, this.deps = this.newDeps, this.newDeps = n, this.newDeps.length = 0 }, fn.prototype.update = function () { this.lazy ? this.dirty = !0 : this.sync ? this.run() : function (e) { var t = e.id; if (null == tn[t]) { if (tn[t] = !0, rn) { for (var n = Qt.length - 1; n > on && Qt[n].id > e.id;)n--; Qt.splice(n + 1, 0, e) } else Qt.push(e); nn || (nn = !0, Ye(un)) } }(this) }, fn.prototype.run = function () { if (this.active) { var e = this.get(); if (e !== this.value || o(e) || this.deep) { var t = this.value; if (this.value = e, this.user) try { this.cb.call(this.vm, e, t) } catch (e) { Re(e, this.vm, 'callback for watcher "' + this.expression + '"') } else this.cb.call(this.vm, e, t) } } }, fn.prototype.evaluate = function () { this.value = this.get(), this.dirty = !1 }, fn.prototype.depend = function () { for (var e = this.deps.length; e--;)this.deps[e].depend() }, fn.prototype.teardown = function () { if (this.active) { this.vm._isBeingDestroyed || h(this.vm._watchers, this); for (var e = this.deps.length; e--;)this.deps[e].removeSub(this); this.active = !1 } }; var pn = { enumerable: !0, configurable: !0, get: S, set: S }; function dn(e, t, n) { pn.get = function () { return this[t][n] }, pn.set = function (e) { this[t][n] = e }, Object.defineProperty(e, n, pn) } function vn(e) { e._watchers = []; var t = e.$options; t.props && function (e, t) { var n = e.$options.propsData || {}, r = e._props = {}, i = e.$options._propKeys = []; e.$parent && $e(!1); var o = function (o) { i.push(o); var a = Me(o, t, n, e); xe(r, o, a), o in e || dn(e, "_props", o) }; for (var a in t) o(a); $e(!0) }(e, t.props), t.methods && function (e, t) { e.$options.props; for (var n in t) e[n] = "function" != typeof t[n] ? S : x(t[n], e) }(e, t.methods), t.data ? function (e) { var t = e.$options.data; s(t = e._data = "function" == typeof t ? function (e, t) { le(); try { return e.call(t, t) } catch (e) { return Re(e, t, "data()"), {} } finally { fe() } }(t, e) : t || {}) || (t = {}); var n = Object.keys(t), r = e.$options.props, i = (e.$options.methods, n.length); for (; i--;){ var o = n[i]; r && y(r, o) || (a = void 0, 36 !== (a = (o + "").charCodeAt(0)) && 95 !== a && dn(e, "_data", o)) } var a; Ce(t, !0) }(e) : Ce(e._data = {}, !0), t.computed && function (e, t) { var n = e._computedWatchers = Object.create(null), r = te(); for (var i in t) { var o = t[i], a = "function" == typeof o ? o : o.get; r || (n[i] = new fn(e, a || S, S, hn)), i in e || mn(e, i, o) } }(e, t.computed), t.watch && t.watch !== Y && function (e, t) { for (var n in t) { var r = t[n]; if (Array.isArray(r)) for (var i = 0; i < r.length; i++)_n(e, n, r[i]); else _n(e, n, r) } }(e, t.watch) } var hn = { lazy: !0 }; function mn(e, t, n) { var r = !te(); "function" == typeof n ? (pn.get = r ? yn(t) : gn(n), pn.set = S) : (pn.get = n.get ? r && !1 !== n.cache ? yn(t) : gn(n.get) : S, pn.set = n.set || S), Object.defineProperty(e, t, pn) } function yn(e) { return function () { var t = this._computedWatchers && this._computedWatchers[e]; if (t) return t.dirty && t.evaluate(), ce.target && t.depend(), t.value } } function gn(e) { return function () { return e.call(this, this) } } function _n(e, t, n, r) { return s(n) && (r = n, n = n.handler), "string" == typeof n && (n = e[n]), e.$watch(t, n, r) } var bn = 0; function $n(e) { var t = e.options; if (e.super) { var n = $n(e.super); if (n !== e.superOptions) { e.superOptions = n; var r = function (e) { var t, n = e.options, r = e.sealedOptions; for (var i in n) n[i] !== r[i] && (t || (t = {}), t[i] = n[i]); return t }(e); r && A(e.extendOptions, r), (t = e.options = De(n, e.extendOptions)).name && (t.components[t.name] = e) } } return t } function wn(e) { this._init(e) } function Cn(e) { e.cid = 0; var t = 1; e.extend = function (e) { e = e || {}; var n = this, r = n.cid, i = e._Ctor || (e._Ctor = {}); if (i[r]) return i[r]; var o = e.name || n.options.name, a = function (e) { this._init(e) }; return (a.prototype = Object.create(n.prototype)).constructor = a, a.cid = t++, a.options = De(n.options, e), a.super = n, a.options.props && function (e) { var t = e.options.props; for (var n in t) dn(e.prototype, "_props", n) }(a), a.options.computed && function (e) { var t = e.options.computed; for (var n in t) mn(e.prototype, n, t[n]) }(a), a.extend = n.extend, a.mixin = n.mixin, a.use = n.use, M.forEach(function (e) { a[e] = n[e] }), o && (a.options.components[o] = a), a.superOptions = n.options, a.extendOptions = e, a.sealedOptions = A({}, a.options), i[r] = a, a } } function xn(e) { return e && (e.Ctor.options.name || e.tag) } function kn(e, t) { return Array.isArray(e) ? e.indexOf(t) > -1 : "string" == typeof e ? e.split(",").indexOf(t) > -1 : (n = e, "[object RegExp]" === a.call(n) && e.test(t)); var n } function An(e, t) { var n = e.cache, r = e.keys, i = e._vnode; for (var o in n) { var a = n[o]; if (a) { var s = xn(a.componentOptions); s && !t(s) && On(n, o, r, i) } } } function On(e, t, n, r) { var i = e[t]; !i || r && i.tag === r.tag || i.componentInstance.$destroy(), e[t] = null, h(n, t) } !function (t) { t.prototype._init = function (t) { var n = this; n._uid = bn++, n._isVue = !0, t && t._isComponent ? function (e, t) { var n = e.$options = Object.create(e.constructor.options), r = t._parentVnode; n.parent = t.parent, n._parentVnode = r; var i = r.componentOptions; n.propsData = i.propsData, n._parentListeners = i.listeners, n._renderChildren = i.children, n._componentTag = i.tag, t.render && (n.render = t.render, n.staticRenderFns = t.staticRenderFns) }(n, t) : n.$options = De($n(n.constructor), t || {}, n), n._renderProxy = n, n._self = n, function (e) { var t = e.$options, n = t.parent; if (n && !t.abstract) { for (; n.$options.abstract && n.$parent;)n = n.$parent; n.$children.push(e) } e.$parent = n, e.$root = n ? n.$root : e, e.$children = [], e.$refs = {}, e._watcher = null, e._inactive = null, e._directInactive = !1, e._isMounted = !1, e._isDestroyed = !1, e._isBeingDestroyed = !1 }(n), function (e) { e._events = Object.create(null), e._hasHookEvent = !1; var t = e.$options._parentListeners; t && qt(e, t) }(n), function (t) { t._vnode = null, t._staticTrees = null; var n = t.$options, r = t.$vnode = n._parentVnode, i = r && r.context; t.$slots = ut(n._renderChildren, i), t.$scopedSlots = e, t._c = function (e, n, r, i) { return Pt(t, e, n, r, i, !1) }, t.$createElement = function (e, n, r, i) { return Pt(t, e, n, r, i, !0) }; var o = r && r.data; xe(t, "$attrs", o && o.attrs || e, null, !0), xe(t, "$listeners", n._parentListeners || e, null, !0) }(n), Yt(n, "beforeCreate"), function (e) { var t = ct(e.$options.inject, e); t && ($e(!1), Object.keys(t).forEach(function (n) { xe(e, n, t[n]) }), $e(!0)) }(n), vn(n), function (e) { var t = e.$options.provide; t && (e._provided = "function" == typeof t ? t.call(e) : t) }(n), Yt(n, "created"), n.$options.el && n.$mount(n.$options.el) } }(wn), function (e) { var t = { get: function () { return this._data } }, n = { get: function () { return this._props } }; Object.defineProperty(e.prototype, "$data", t), Object.defineProperty(e.prototype, "$props", n), e.prototype.$set = ke, e.prototype.$delete = Ae, e.prototype.$watch = function (e, t, n) { if (s(t)) return _n(this, e, t, n); (n = n || {}).user = !0; var r = new fn(this, e, t, n); if (n.immediate) try { t.call(this, r.value) } catch (e) { Re(e, this, 'callback for immediate watcher "' + r.expression + '"') } return function () { r.teardown() } } }(wn), function (e) { var t = /^hook:/; e.prototype.$on = function (e, n) { var r = this; if (Array.isArray(e)) for (var i = 0, o = e.length; i < o; i++)r.$on(e[i], n); else (r._events[e] || (r._events[e] = [])).push(n), t.test(e) && (r._hasHookEvent = !0); return r }, e.prototype.$once = function (e, t) { var n = this; function r() { n.$off(e, r), t.apply(n, arguments) } return r.fn = t, n.$on(e, r), n }, e.prototype.$off = function (e, t) { var n = this; if (!arguments.length) return n._events = Object.create(null), n; if (Array.isArray(e)) { for (var r = 0, i = e.length; r < i; r++)n.$off(e[r], t); return n } var o, a = n._events[e]; if (!a) return n; if (!t) return n._events[e] = null, n; for (var s = a.length; s--;)if ((o = a[s]) === t || o.fn === t) { a.splice(s, 1); break } return n }, e.prototype.$emit = function (e) { var t = this._events[e]; if (t) { t = t.length > 1 ? k(t) : t; for (var n = k(arguments, 1), r = 'event handler for "' + e + '"', i = 0, o = t.length; i < o; i++)He(t[i], this, n, this, r) } return this } }(wn), function (e) { e.prototype._update = function (e, t) { var n = this, r = n.$el, i = n._vnode, o = Zt(n); n._vnode = e, n.$el = i ? n.__patch__(i, e) : n.__patch__(n.$el, e, t, !1), o(), r && (r.__vue__ = null), n.$el && (n.$el.__vue__ = n), n.$vnode && n.$parent && n.$vnode === n.$parent._vnode && (n.$parent.$el = n.$el) }, e.prototype.$forceUpdate = function () { this._watcher && this._watcher.update() }, e.prototype.$destroy = function () { var e = this; if (!e._isBeingDestroyed) { Yt(e, "beforeDestroy"), e._isBeingDestroyed = !0; var t = e.$parent; !t || t._isBeingDestroyed || e.$options.abstract || h(t.$children, e), e._watcher && e._watcher.teardown(); for (var n = e._watchers.length; n--;)e._watchers[n].teardown(); e._data.__ob__ && e._data.__ob__.vmCount--, e._isDestroyed = !0, e.__patch__(e._vnode, null), Yt(e, "destroyed"), e.$off(), e.$el && (e.$el.__vue__ = null), e.$vnode && (e.$vnode.parent = null) } } }(wn), function (e) { St(e.prototype), e.prototype.$nextTick = function (e) { return Ye(e, this) }, e.prototype._render = function () { var e, t = this, n = t.$options, r = n.render, i = n._parentVnode; i && (t.$scopedSlots = ft(i.data.scopedSlots, t.$slots, t.$scopedSlots)), t.$vnode = i; try { Ht = t, e = r.call(t._renderProxy, t.$createElement) } catch (n) { Re(n, t, "render"), e = t._vnode } finally { Ht = null } return Array.isArray(e) && 1 === e.length && (e = e[0]), e instanceof pe || (e = ve()), e.parent = i, e } }(wn); var Sn = [String, RegExp, Array], Tn = { KeepAlive: { name: "keep-alive", abstract: !0, props: { include: Sn, exclude: Sn, max: [String, Number] }, created: function () { this.cache = Object.create(null), this.keys = [] }, destroyed: function () { for (var e in this.cache) On(this.cache, e, this.keys) }, mounted: function () { var e = this; this.$watch("include", function (t) { An(e, function (e) { return kn(t, e) }) }), this.$watch("exclude", function (t) { An(e, function (e) { return !kn(t, e) }) }) }, render: function () { var e = this.$slots.default, t = zt(e), n = t && t.componentOptions; if (n) { var r = xn(n), i = this.include, o = this.exclude; if (i && (!r || !kn(i, r)) || o && r && kn(o, r)) return t; var a = this.cache, s = this.keys, c = null == t.key ? n.Ctor.cid + (n.tag ? "::" + n.tag : "") : t.key; a[c] ? (t.componentInstance = a[c].componentInstance, h(s, c), s.push(c)) : (a[c] = t, s.push(c), this.max && s.length > parseInt(this.max) && On(a, s[0], s, this._vnode)), t.data.keepAlive = !0 } return t || e && e[0] } } }; !function (e) { var t = { get: function () { return F } }; Object.defineProperty(e, "config", t), e.util = { warn: ae, extend: A, mergeOptions: De, defineReactive: xe }, e.set = ke, e.delete = Ae, e.nextTick = Ye, e.observable = function (e) { return Ce(e), e }, e.options = Object.create(null), M.forEach(function (t) { e.options[t + "s"] = Object.create(null) }), e.options._base = e, A(e.options.components, Tn), function (e) { e.use = function (e) { var t = this._installedPlugins || (this._installedPlugins = []); if (t.indexOf(e) > -1) return this; var n = k(arguments, 1); return n.unshift(this), "function" == typeof e.install ? e.install.apply(e, n) : "function" == typeof e && e.apply(null, n), t.push(e), this } }(e), function (e) { e.mixin = function (e) { return this.options = De(this.options, e), this } }(e), Cn(e), function (e) { M.forEach(function (t) { e[t] = function (e, n) { return n ? ("component" === t && s(n) && (n.name = n.name || e, n = this.options._base.extend(n)), "directive" === t && "function" == typeof n && (n = { bind: n, update: n }), this.options[t + "s"][e] = n, n) : this.options[t + "s"][e] } }) }(e) }(wn), Object.defineProperty(wn.prototype, "$isServer", { get: te }), Object.defineProperty(wn.prototype, "$ssrContext", { get: function () { return this.$vnode && this.$vnode.ssrContext } }), Object.defineProperty(wn, "FunctionalRenderContext", { value: Tt }), wn.version = "2.6.11"; var En = p("style,class"), Nn = p("input,textarea,option,select,progress"), jn = function (e, t, n) { return "value" === n && Nn(e) && "button" !== t || "selected" === n && "option" === e || "checked" === n && "input" === e || "muted" === n && "video" === e }, Dn = p("contenteditable,draggable,spellcheck"), Ln = p("events,caret,typing,plaintext-only"), Mn = function (e, t) { return Hn(t) || "false" === t ? "false" : "contenteditable" === e && Ln(t) ? t : "true" }, In = p("allowfullscreen,async,autofocus,autoplay,checked,compact,controls,declare,default,defaultchecked,defaultmuted,defaultselected,defer,disabled,enabled,formnovalidate,hidden,indeterminate,inert,ismap,itemscope,loop,multiple,muted,nohref,noresize,noshade,novalidate,nowrap,open,pauseonexit,readonly,required,reversed,scoped,seamless,selected,sortable,translate,truespeed,typemustmatch,visible"), Fn = "http://www.w3.org/1999/xlink", Pn = function (e) { return ":" === e.charAt(5) && "xlink" === e.slice(0, 5) }, Rn = function (e) { return Pn(e) ? e.slice(6, e.length) : "" }, Hn = function (e) { return null == e || !1 === e }; function Bn(e) { for (var t = e.data, r = e, i = e; n(i.componentInstance);)(i = i.componentInstance._vnode) && i.data && (t = Un(i.data, t)); for (; n(r = r.parent);)r && r.data && (t = Un(t, r.data)); return function (e, t) { if (n(e) || n(t)) return zn(e, Vn(t)); return "" }(t.staticClass, t.class) } function Un(e, t) { return { staticClass: zn(e.staticClass, t.staticClass), class: n(e.class) ? [e.class, t.class] : t.class } } function zn(e, t) { return e ? t ? e + " " + t : e : t || "" } function Vn(e) { return Array.isArray(e) ? function (e) { for (var t, r = "", i = 0, o = e.length; i < o; i++)n(t = Vn(e[i])) && "" !== t && (r && (r += " "), r += t); return r }(e) : o(e) ? function (e) { var t = ""; for (var n in e) e[n] && (t && (t += " "), t += n); return t }(e) : "string" == typeof e ? e : "" } var Kn = { svg: "http://www.w3.org/2000/svg", math: "http://www.w3.org/1998/Math/MathML" }, Jn = p("html,body,base,head,link,meta,style,title,address,article,aside,footer,header,h1,h2,h3,h4,h5,h6,hgroup,nav,section,div,dd,dl,dt,figcaption,figure,picture,hr,img,li,main,ol,p,pre,ul,a,b,abbr,bdi,bdo,br,cite,code,data,dfn,em,i,kbd,mark,q,rp,rt,rtc,ruby,s,samp,small,span,strong,sub,sup,time,u,var,wbr,area,audio,map,track,video,embed,object,param,source,canvas,script,noscript,del,ins,caption,col,colgroup,table,thead,tbody,td,th,tr,button,datalist,fieldset,form,input,label,legend,meter,optgroup,option,output,progress,select,textarea,details,dialog,menu,menuitem,summary,content,element,shadow,template,blockquote,iframe,tfoot"), qn = p("svg,animate,circle,clippath,cursor,defs,desc,ellipse,filter,font-face,foreignObject,g,glyph,image,line,marker,mask,missing-glyph,path,pattern,polygon,polyline,rect,switch,symbol,text,textpath,tspan,use,view", !0), Wn = function (e) { return Jn(e) || qn(e) }; function Zn(e) { return qn(e) ? "svg" : "math" === e ? "math" : void 0 } var Gn = Object.create(null); var Xn = p("text,number,password,search,email,tel,url"); function Yn(e) { if ("string" == typeof e) { var t = document.querySelector(e); return t || document.createElement("div") } return e } var Qn = Object.freeze({ createElement: function (e, t) { var n = document.createElement(e); return "select" !== e ? n : (t.data && t.data.attrs && void 0 !== t.data.attrs.multiple && n.setAttribute("multiple", "multiple"), n) }, createElementNS: function (e, t) { return document.createElementNS(Kn[e], t) }, createTextNode: function (e) { return document.createTextNode(e) }, createComment: function (e) { return document.createComment(e) }, insertBefore: function (e, t, n) { e.insertBefore(t, n) }, removeChild: function (e, t) { e.removeChild(t) }, appendChild: function (e, t) { e.appendChild(t) }, parentNode: function (e) { return e.parentNode }, nextSibling: function (e) { return e.nextSibling }, tagName: function (e) { return e.tagName }, setTextContent: function (e, t) { e.textContent = t }, setStyleScope: function (e, t) { e.setAttribute(t, "") } }), er = { create: function (e, t) { tr(t) }, update: function (e, t) { e.data.ref !== t.data.ref && (tr(e, !0), tr(t)) }, destroy: function (e) { tr(e, !0) } }; function tr(e, t) { var r = e.data.ref; if (n(r)) { var i = e.context, o = e.componentInstance || e.elm, a = i.$refs; t ? Array.isArray(a[r]) ? h(a[r], o) : a[r] === o && (a[r] = void 0) : e.data.refInFor ? Array.isArray(a[r]) ? a[r].indexOf(o) < 0 && a[r].push(o) : a[r] = [o] : a[r] = o } } var nr = new pe("", {}, []), rr = ["create", "activate", "update", "remove", "destroy"]; function ir(e, i) { return e.key === i.key && (e.tag === i.tag && e.isComment === i.isComment && n(e.data) === n(i.data) && function (e, t) { if ("input" !== e.tag) return !0; var r, i = n(r = e.data) && n(r = r.attrs) && r.type, o = n(r = t.data) && n(r = r.attrs) && r.type; return i === o || Xn(i) && Xn(o) }(e, i) || r(e.isAsyncPlaceholder) && e.asyncFactory === i.asyncFactory && t(i.asyncFactory.error)) } function or(e, t, r) { var i, o, a = {}; for (i = t; i <= r; ++i)n(o = e[i].key) && (a[o] = i); return a } var ar = { create: sr, update: sr, destroy: function (e) { sr(e, nr) } }; function sr(e, t) { (e.data.directives || t.data.directives) && function (e, t) { var n, r, i, o = e === nr, a = t === nr, s = ur(e.data.directives, e.context), c = ur(t.data.directives, t.context), u = [], l = []; for (n in c) r = s[n], i = c[n], r ? (i.oldValue = r.value, i.oldArg = r.arg, fr(i, "update", t, e), i.def && i.def.componentUpdated && l.push(i)) : (fr(i, "bind", t, e), i.def && i.def.inserted && u.push(i)); if (u.length) { var f = function () { for (var n = 0; n < u.length; n++)fr(u[n], "inserted", t, e) }; o ? it(t, "insert", f) : f() } l.length && it(t, "postpatch", function () { for (var n = 0; n < l.length; n++)fr(l[n], "componentUpdated", t, e) }); if (!o) for (n in s) c[n] || fr(s[n], "unbind", e, e, a) }(e, t) } var cr = Object.create(null); function ur(e, t) { var n, r, i = Object.create(null); if (!e) return i; for (n = 0; n < e.length; n++)(r = e[n]).modifiers || (r.modifiers = cr), i[lr(r)] = r, r.def = Le(t.$options, "directives", r.name); return i } function lr(e) { return e.rawName || e.name + "." + Object.keys(e.modifiers || {}).join(".") } function fr(e, t, n, r, i) { var o = e.def && e.def[t]; if (o) try { o(n.elm, e, n, r, i) } catch (r) { Re(r, n.context, "directive " + e.name + " " + t + " hook") } } var pr = [er, ar]; function dr(e, r) { var i = r.componentOptions; if (!(n(i) && !1 === i.Ctor.options.inheritAttrs || t(e.data.attrs) && t(r.data.attrs))) { var o, a, s = r.elm, c = e.data.attrs || {}, u = r.data.attrs || {}; for (o in n(u.__ob__) && (u = r.data.attrs = A({}, u)), u) a = u[o], c[o] !== a && vr(s, o, a); for (o in (q || Z) && u.value !== c.value && vr(s, "value", u.value), c) t(u[o]) && (Pn(o) ? s.removeAttributeNS(Fn, Rn(o)) : Dn(o) || s.removeAttribute(o)) } } function vr(e, t, n) { e.tagName.indexOf("-") > -1 ? hr(e, t, n) : In(t) ? Hn(n) ? e.removeAttribute(t) : (n = "allowfullscreen" === t && "EMBED" === e.tagName ? "true" : t, e.setAttribute(t, n)) : Dn(t) ? e.setAttribute(t, Mn(t, n)) : Pn(t) ? Hn(n) ? e.removeAttributeNS(Fn, Rn(t)) : e.setAttributeNS(Fn, t, n) : hr(e, t, n) } function hr(e, t, n) { if (Hn(n)) e.removeAttribute(t); else { if (q && !W && "TEXTAREA" === e.tagName && "placeholder" === t && "" !== n && !e.__ieph) { var r = function (t) { t.stopImmediatePropagation(), e.removeEventListener("input", r) }; e.addEventListener("input", r), e.__ieph = !0 } e.setAttribute(t, n) } } var mr = { create: dr, update: dr }; function yr(e, r) { var i = r.elm, o = r.data, a = e.data; if (!(t(o.staticClass) && t(o.class) && (t(a) || t(a.staticClass) && t(a.class)))) { var s = Bn(r), c = i._transitionClasses; n(c) && (s = zn(s, Vn(c))), s !== i._prevClass && (i.setAttribute("class", s), i._prevClass = s) } } var gr, _r, br, $r, wr, Cr, xr = { create: yr, update: yr }, kr = /[\w).+\-_$\]]/; function Ar(e) { var t, n, r, i, o, a = !1, s = !1, c = !1, u = !1, l = 0, f = 0, p = 0, d = 0; for (r = 0; r < e.length; r++)if (n = t, t = e.charCodeAt(r), a) 39 === t && 92 !== n && (a = !1); else if (s) 34 === t && 92 !== n && (s = !1); else if (c) 96 === t && 92 !== n && (c = !1); else if (u) 47 === t && 92 !== n && (u = !1); else if (124 !== t || 124 === e.charCodeAt(r + 1) || 124 === e.charCodeAt(r - 1) || l || f || p) { switch (t) { case 34: s = !0; break; case 39: a = !0; break; case 96: c = !0; break; case 40: p++; break; case 41: p--; break; case 91: f++; break; case 93: f--; break; case 123: l++; break; case 125: l-- }if (47 === t) { for (var v = r - 1, h = void 0; v >= 0 && " " === (h = e.charAt(v)); v--); h && kr.test(h) || (u = !0) } } else void 0 === i ? (d = r + 1, i = e.slice(0, r).trim()) : m(); function m() { (o || (o = [])).push(e.slice(d, r).trim()), d = r + 1 } if (void 0 === i ? i = e.slice(0, r).trim() : 0 !== d && m(), o) for (r = 0; r < o.length; r++)i = Or(i, o[r]); return i } function Or(e, t) { var n = t.indexOf("("); if (n < 0) return '_f("' + t + '")(' + e + ")"; var r = t.slice(0, n), i = t.slice(n + 1); return '_f("' + r + '")(' + e + (")" !== i ? "," + i : i) } function Sr(e, t) { console.error("[Vue compiler]: " + e) } function Tr(e, t) { return e ? e.map(function (e) { return e[t] }).filter(function (e) { return e }) : [] } function Er(e, t, n, r, i) { (e.props || (e.props = [])).push(Rr({ name: t, value: n, dynamic: i }, r)), e.plain = !1 } function Nr(e, t, n, r, i) { (i ? e.dynamicAttrs || (e.dynamicAttrs = []) : e.attrs || (e.attrs = [])).push(Rr({ name: t, value: n, dynamic: i }, r)), e.plain = !1 } function jr(e, t, n, r) { e.attrsMap[t] = n, e.attrsList.push(Rr({ name: t, value: n }, r)) } function Dr(e, t, n, r, i, o, a, s) { (e.directives || (e.directives = [])).push(Rr({ name: t, rawName: n, value: r, arg: i, isDynamicArg: o, modifiers: a }, s)), e.plain = !1 } function Lr(e, t, n) { return n ? "_p(" + t + ',"' + e + '")' : e + t } function Mr(t, n, r, i, o, a, s, c) { var u; (i = i || e).right ? c ? n = "(" + n + ")==='click'?'contextmenu':(" + n + ")" : "click" === n && (n = "contextmenu", delete i.right) : i.middle && (c ? n = "(" + n + ")==='click'?'mouseup':(" + n + ")" : "click" === n && (n = "mouseup")), i.capture && (delete i.capture, n = Lr("!", n, c)), i.once && (delete i.once, n = Lr("~", n, c)), i.passive && (delete i.passive, n = Lr("&", n, c)), i.native ? (delete i.native, u = t.nativeEvents || (t.nativeEvents = {})) : u = t.events || (t.events = {}); var l = Rr({ value: r.trim(), dynamic: c }, s); i !== e && (l.modifiers = i); var f = u[n]; Array.isArray(f) ? o ? f.unshift(l) : f.push(l) : u[n] = f ? o ? [l, f] : [f, l] : l, t.plain = !1 } function Ir(e, t, n) { var r = Fr(e, ":" + t) || Fr(e, "v-bind:" + t); if (null != r) return Ar(r); if (!1 !== n) { var i = Fr(e, t); if (null != i) return JSON.stringify(i) } } function Fr(e, t, n) { var r; if (null != (r = e.attrsMap[t])) for (var i = e.attrsList, o = 0, a = i.length; o < a; o++)if (i[o].name === t) { i.splice(o, 1); break } return n && delete e.attrsMap[t], r } function Pr(e, t) { for (var n = e.attrsList, r = 0, i = n.length; r < i; r++){ var o = n[r]; if (t.test(o.name)) return n.splice(r, 1), o } } function Rr(e, t) { return t && (null != t.start && (e.start = t.start), null != t.end && (e.end = t.end)), e } function Hr(e, t, n) { var r = n || {}, i = r.number, o = "$$v"; r.trim && (o = "(typeof $$v === 'string'? $$v.trim(): $$v)"), i && (o = "_n(" + o + ")"); var a = Br(t, o); e.model = { value: "(" + t + ")", expression: JSON.stringify(t), callback: "function ($$v) {" + a + "}" } } function Br(e, t) { var n = function (e) { if (e = e.trim(), gr = e.length, e.indexOf("[") < 0 || e.lastIndexOf("]") < gr - 1) return ($r = e.lastIndexOf(".")) > -1 ? { exp: e.slice(0, $r), key: '"' + e.slice($r + 1) + '"' } : { exp: e, key: null }; _r = e, $r = wr = Cr = 0; for (; !zr();)Vr(br = Ur()) ? Jr(br) : 91 === br && Kr(br); return { exp: e.slice(0, wr), key: e.slice(wr + 1, Cr) } }(e); return null === n.key ? e + "=" + t : "$set(" + n.exp + ", " + n.key + ", " + t + ")" } function Ur() { return _r.charCodeAt(++$r) } function zr() { return $r >= gr } function Vr(e) { return 34 === e || 39 === e } function Kr(e) { var t = 1; for (wr = $r; !zr();)if (Vr(e = Ur())) Jr(e); else if (91 === e && t++, 93 === e && t--, 0 === t) { Cr = $r; break } } function Jr(e) { for (var t = e; !zr() && (e = Ur()) !== t;); } var qr, Wr = "__r", Zr = "__c"; function Gr(e, t, n) { var r = qr; return function i() { null !== t.apply(null, arguments) && Qr(e, i, n, r) } } var Xr = Ve && !(X && Number(X[1]) <= 53); function Yr(e, t, n, r) { if (Xr) { var i = an, o = t; t = o._wrapper = function (e) { if (e.target === e.currentTarget || e.timeStamp >= i || e.timeStamp <= 0 || e.target.ownerDocument !== document) return o.apply(this, arguments) } } qr.addEventListener(e, t, Q ? { capture: n, passive: r } : n) } function Qr(e, t, n, r) { (r || qr).removeEventListener(e, t._wrapper || t, n) } function ei(e, r) { if (!t(e.data.on) || !t(r.data.on)) { var i = r.data.on || {}, o = e.data.on || {}; qr = r.elm, function (e) { if (n(e[Wr])) { var t = q ? "change" : "input"; e[t] = [].concat(e[Wr], e[t] || []), delete e[Wr] } n(e[Zr]) && (e.change = [].concat(e[Zr], e.change || []), delete e[Zr]) }(i), rt(i, o, Yr, Qr, Gr, r.context), qr = void 0 } } var ti, ni = { create: ei, update: ei }; function ri(e, r) { if (!t(e.data.domProps) || !t(r.data.domProps)) { var i, o, a = r.elm, s = e.data.domProps || {}, c = r.data.domProps || {}; for (i in n(c.__ob__) && (c = r.data.domProps = A({}, c)), s) i in c || (a[i] = ""); for (i in c) { if (o = c[i], "textContent" === i || "innerHTML" === i) { if (r.children && (r.children.length = 0), o === s[i]) continue; 1 === a.childNodes.length && a.removeChild(a.childNodes[0]) } if ("value" === i && "PROGRESS" !== a.tagName) { a._value = o; var u = t(o) ? "" : String(o); ii(a, u) && (a.value = u) } else if ("innerHTML" === i && qn(a.tagName) && t(a.innerHTML)) { (ti = ti || document.createElement("div")).innerHTML = "<svg>" + o + "</svg>"; for (var l = ti.firstChild; a.firstChild;)a.removeChild(a.firstChild); for (; l.firstChild;)a.appendChild(l.firstChild) } else if (o !== s[i]) try { a[i] = o } catch (e) { } } } } function ii(e, t) { return !e.composing && ("OPTION" === e.tagName || function (e, t) { var n = !0; try { n = document.activeElement !== e } catch (e) { } return n && e.value !== t }(e, t) || function (e, t) { var r = e.value, i = e._vModifiers; if (n(i)) { if (i.number) return f(r) !== f(t); if (i.trim) return r.trim() !== t.trim() } return r !== t }(e, t)) } var oi = { create: ri, update: ri }, ai = g(function (e) { var t = {}, n = /:(.+)/; return e.split(/;(?![^(]*\))/g).forEach(function (e) { if (e) { var r = e.split(n); r.length > 1 && (t[r[0].trim()] = r[1].trim()) } }), t }); function si(e) { var t = ci(e.style); return e.staticStyle ? A(e.staticStyle, t) : t } function ci(e) { return Array.isArray(e) ? O(e) : "string" == typeof e ? ai(e) : e } var ui, li = /^--/, fi = /\s*!important$/, pi = function (e, t, n) { if (li.test(t)) e.style.setProperty(t, n); else if (fi.test(n)) e.style.setProperty(C(t), n.replace(fi, ""), "important"); else { var r = vi(t); if (Array.isArray(n)) for (var i = 0, o = n.length; i < o; i++)e.style[r] = n[i]; else e.style[r] = n } }, di = ["Webkit", "Moz", "ms"], vi = g(function (e) { if (ui = ui || document.createElement("div").style, "filter" !== (e = b(e)) && e in ui) return e; for (var t = e.charAt(0).toUpperCase() + e.slice(1), n = 0; n < di.length; n++){ var r = di[n] + t; if (r in ui) return r } }); function hi(e, r) { var i = r.data, o = e.data; if (!(t(i.staticStyle) && t(i.style) && t(o.staticStyle) && t(o.style))) { var a, s, c = r.elm, u = o.staticStyle, l = o.normalizedStyle || o.style || {}, f = u || l, p = ci(r.data.style) || {}; r.data.normalizedStyle = n(p.__ob__) ? A({}, p) : p; var d = function (e, t) { var n, r = {}; if (t) for (var i = e; i.componentInstance;)(i = i.componentInstance._vnode) && i.data && (n = si(i.data)) && A(r, n); (n = si(e.data)) && A(r, n); for (var o = e; o = o.parent;)o.data && (n = si(o.data)) && A(r, n); return r }(r, !0); for (s in f) t(d[s]) && pi(c, s, ""); for (s in d) (a = d[s]) !== f[s] && pi(c, s, null == a ? "" : a) } } var mi = { create: hi, update: hi }, yi = /\s+/; function gi(e, t) { if (t && (t = t.trim())) if (e.classList) t.indexOf(" ") > -1 ? t.split(yi).forEach(function (t) { return e.classList.add(t) }) : e.classList.add(t); else { var n = " " + (e.getAttribute("class") || "") + " "; n.indexOf(" " + t + " ") < 0 && e.setAttribute("class", (n + t).trim()) } } function _i(e, t) { if (t && (t = t.trim())) if (e.classList) t.indexOf(" ") > -1 ? t.split(yi).forEach(function (t) { return e.classList.remove(t) }) : e.classList.remove(t), e.classList.length || e.removeAttribute("class"); else { for (var n = " " + (e.getAttribute("class") || "") + " ", r = " " + t + " "; n.indexOf(r) >= 0;)n = n.replace(r, " "); (n = n.trim()) ? e.setAttribute("class", n) : e.removeAttribute("class") } } function bi(e) { if (e) { if ("object" == typeof e) { var t = {}; return !1 !== e.css && A(t, $i(e.name || "v")), A(t, e), t } return "string" == typeof e ? $i(e) : void 0 } } var $i = g(function (e) { return { enterClass: e + "-enter", enterToClass: e + "-enter-to", enterActiveClass: e + "-enter-active", leaveClass: e + "-leave", leaveToClass: e + "-leave-to", leaveActiveClass: e + "-leave-active" } }), wi = z && !W, Ci = "transition", xi = "animation", ki = "transition", Ai = "transitionend", Oi = "animation", Si = "animationend"; wi && (void 0 === window.ontransitionend && void 0 !== window.onwebkittransitionend && (ki = "WebkitTransition", Ai = "webkitTransitionEnd"), void 0 === window.onanimationend && void 0 !== window.onwebkitanimationend && (Oi = "WebkitAnimation", Si = "webkitAnimationEnd")); var Ti = z ? window.requestAnimationFrame ? window.requestAnimationFrame.bind(window) : setTimeout : function (e) { return e() }; function Ei(e) { Ti(function () { Ti(e) }) } function Ni(e, t) { var n = e._transitionClasses || (e._transitionClasses = []); n.indexOf(t) < 0 && (n.push(t), gi(e, t)) } function ji(e, t) { e._transitionClasses && h(e._transitionClasses, t), _i(e, t) } function Di(e, t, n) { var r = Mi(e, t), i = r.type, o = r.timeout, a = r.propCount; if (!i) return n(); var s = i === Ci ? Ai : Si, c = 0, u = function () { e.removeEventListener(s, l), n() }, l = function (t) { t.target === e && ++c >= a && u() }; setTimeout(function () { c < a && u() }, o + 1), e.addEventListener(s, l) } var Li = /\b(transform|all)(,|$)/; function Mi(e, t) { var n, r = window.getComputedStyle(e), i = (r[ki + "Delay"] || "").split(", "), o = (r[ki + "Duration"] || "").split(", "), a = Ii(i, o), s = (r[Oi + "Delay"] || "").split(", "), c = (r[Oi + "Duration"] || "").split(", "), u = Ii(s, c), l = 0, f = 0; return t === Ci ? a > 0 && (n = Ci, l = a, f = o.length) : t === xi ? u > 0 && (n = xi, l = u, f = c.length) : f = (n = (l = Math.max(a, u)) > 0 ? a > u ? Ci : xi : null) ? n === Ci ? o.length : c.length : 0, { type: n, timeout: l, propCount: f, hasTransform: n === Ci && Li.test(r[ki + "Property"]) } } function Ii(e, t) { for (; e.length < t.length;)e = e.concat(e); return Math.max.apply(null, t.map(function (t, n) { return Fi(t) + Fi(e[n]) })) } function Fi(e) { return 1e3 * Number(e.slice(0, -1).replace(",", ".")) } function Pi(e, r) { var i = e.elm; n(i._leaveCb) && (i._leaveCb.cancelled = !0, i._leaveCb()); var a = bi(e.data.transition); if (!t(a) && !n(i._enterCb) && 1 === i.nodeType) { for (var s = a.css, c = a.type, u = a.enterClass, l = a.enterToClass, p = a.enterActiveClass, d = a.appearClass, v = a.appearToClass, h = a.appearActiveClass, m = a.beforeEnter, y = a.enter, g = a.afterEnter, _ = a.enterCancelled, b = a.beforeAppear, $ = a.appear, w = a.afterAppear, C = a.appearCancelled, x = a.duration, k = Wt, A = Wt.$vnode; A && A.parent;)k = A.context, A = A.parent; var O = !k._isMounted || !e.isRootInsert; if (!O || $ || "" === $) { var S = O && d ? d : u, T = O && h ? h : p, E = O && v ? v : l, N = O && b || m, j = O && "function" == typeof $ ? $ : y, L = O && w || g, M = O && C || _, I = f(o(x) ? x.enter : x), F = !1 !== s && !W, P = Bi(j), R = i._enterCb = D(function () { F && (ji(i, E), ji(i, T)), R.cancelled ? (F && ji(i, S), M && M(i)) : L && L(i), i._enterCb = null }); e.data.show || it(e, "insert", function () { var t = i.parentNode, n = t && t._pending && t._pending[e.key]; n && n.tag === e.tag && n.elm._leaveCb && n.elm._leaveCb(), j && j(i, R) }), N && N(i), F && (Ni(i, S), Ni(i, T), Ei(function () { ji(i, S), R.cancelled || (Ni(i, E), P || (Hi(I) ? setTimeout(R, I) : Di(i, c, R))) })), e.data.show && (r && r(), j && j(i, R)), F || P || R() } } } function Ri(e, r) { var i = e.elm; n(i._enterCb) && (i._enterCb.cancelled = !0, i._enterCb()); var a = bi(e.data.transition); if (t(a) || 1 !== i.nodeType) return r(); if (!n(i._leaveCb)) { var s = a.css, c = a.type, u = a.leaveClass, l = a.leaveToClass, p = a.leaveActiveClass, d = a.beforeLeave, v = a.leave, h = a.afterLeave, m = a.leaveCancelled, y = a.delayLeave, g = a.duration, _ = !1 !== s && !W, b = Bi(v), $ = f(o(g) ? g.leave : g), w = i._leaveCb = D(function () { i.parentNode && i.parentNode._pending && (i.parentNode._pending[e.key] = null), _ && (ji(i, l), ji(i, p)), w.cancelled ? (_ && ji(i, u), m && m(i)) : (r(), h && h(i)), i._leaveCb = null }); y ? y(C) : C() } function C() { w.cancelled || (!e.data.show && i.parentNode && ((i.parentNode._pending || (i.parentNode._pending = {}))[e.key] = e), d && d(i), _ && (Ni(i, u), Ni(i, p), Ei(function () { ji(i, u), w.cancelled || (Ni(i, l), b || (Hi($) ? setTimeout(w, $) : Di(i, c, w))) })), v && v(i, w), _ || b || w()) } } function Hi(e) { return "number" == typeof e && !isNaN(e) } function Bi(e) { if (t(e)) return !1; var r = e.fns; return n(r) ? Bi(Array.isArray(r) ? r[0] : r) : (e._length || e.length) > 1 } function Ui(e, t) { !0 !== t.data.show && Pi(t) } var zi = function (e) { var o, a, s = {}, c = e.modules, u = e.nodeOps; for (o = 0; o < rr.length; ++o)for (s[rr[o]] = [], a = 0; a < c.length; ++a)n(c[a][rr[o]]) && s[rr[o]].push(c[a][rr[o]]); function l(e) { var t = u.parentNode(e); n(t) && u.removeChild(t, e) } function f(e, t, i, o, a, c, l) { if (n(e.elm) && n(c) && (e = c[l] = me(e)), e.isRootInsert = !a, !function (e, t, i, o) { var a = e.data; if (n(a)) { var c = n(e.componentInstance) && a.keepAlive; if (n(a = a.hook) && n(a = a.init) && a(e, !1), n(e.componentInstance)) return d(e, t), v(i, e.elm, o), r(c) && function (e, t, r, i) { for (var o, a = e; a.componentInstance;)if (a = a.componentInstance._vnode, n(o = a.data) && n(o = o.transition)) { for (o = 0; o < s.activate.length; ++o)s.activate[o](nr, a); t.push(a); break } v(r, e.elm, i) }(e, t, i, o), !0 } }(e, t, i, o)) { var f = e.data, p = e.children, m = e.tag; n(m) ? (e.elm = e.ns ? u.createElementNS(e.ns, m) : u.createElement(m, e), g(e), h(e, p, t), n(f) && y(e, t), v(i, e.elm, o)) : r(e.isComment) ? (e.elm = u.createComment(e.text), v(i, e.elm, o)) : (e.elm = u.createTextNode(e.text), v(i, e.elm, o)) } } function d(e, t) { n(e.data.pendingInsert) && (t.push.apply(t, e.data.pendingInsert), e.data.pendingInsert = null), e.elm = e.componentInstance.$el, m(e) ? (y(e, t), g(e)) : (tr(e), t.push(e)) } function v(e, t, r) { n(e) && (n(r) ? u.parentNode(r) === e && u.insertBefore(e, t, r) : u.appendChild(e, t)) } function h(e, t, n) { if (Array.isArray(t)) for (var r = 0; r < t.length; ++r)f(t[r], n, e.elm, null, !0, t, r); else i(e.text) && u.appendChild(e.elm, u.createTextNode(String(e.text))) } function m(e) { for (; e.componentInstance;)e = e.componentInstance._vnode; return n(e.tag) } function y(e, t) { for (var r = 0; r < s.create.length; ++r)s.create[r](nr, e); n(o = e.data.hook) && (n(o.create) && o.create(nr, e), n(o.insert) && t.push(e)) } function g(e) { var t; if (n(t = e.fnScopeId)) u.setStyleScope(e.elm, t); else for (var r = e; r;)n(t = r.context) && n(t = t.$options._scopeId) && u.setStyleScope(e.elm, t), r = r.parent; n(t = Wt) && t !== e.context && t !== e.fnContext && n(t = t.$options._scopeId) && u.setStyleScope(e.elm, t) } function _(e, t, n, r, i, o) { for (; r <= i; ++r)f(n[r], o, e, t, !1, n, r) } function b(e) { var t, r, i = e.data; if (n(i)) for (n(t = i.hook) && n(t = t.destroy) && t(e), t = 0; t < s.destroy.length; ++t)s.destroy[t](e); if (n(t = e.children)) for (r = 0; r < e.children.length; ++r)b(e.children[r]) } function $(e, t, r) { for (; t <= r; ++t){ var i = e[t]; n(i) && (n(i.tag) ? (w(i), b(i)) : l(i.elm)) } } function w(e, t) { if (n(t) || n(e.data)) { var r, i = s.remove.length + 1; for (n(t) ? t.listeners += i : t = function (e, t) { function n() { 0 == --n.listeners && l(e) } return n.listeners = t, n }(e.elm, i), n(r = e.componentInstance) && n(r = r._vnode) && n(r.data) && w(r, t), r = 0; r < s.remove.length; ++r)s.remove[r](e, t); n(r = e.data.hook) && n(r = r.remove) ? r(e, t) : t() } else l(e.elm) } function C(e, t, r, i) { for (var o = r; o < i; o++){ var a = t[o]; if (n(a) && ir(e, a)) return o } } function x(e, i, o, a, c, l) { if (e !== i) { n(i.elm) && n(a) && (i = a[c] = me(i)); var p = i.elm = e.elm; if (r(e.isAsyncPlaceholder)) n(i.asyncFactory.resolved) ? O(e.elm, i, o) : i.isAsyncPlaceholder = !0; else if (r(i.isStatic) && r(e.isStatic) && i.key === e.key && (r(i.isCloned) || r(i.isOnce))) i.componentInstance = e.componentInstance; else { var d, v = i.data; n(v) && n(d = v.hook) && n(d = d.prepatch) && d(e, i); var h = e.children, y = i.children; if (n(v) && m(i)) { for (d = 0; d < s.update.length; ++d)s.update[d](e, i); n(d = v.hook) && n(d = d.update) && d(e, i) } t(i.text) ? n(h) && n(y) ? h !== y && function (e, r, i, o, a) { for (var s, c, l, p = 0, d = 0, v = r.length - 1, h = r[0], m = r[v], y = i.length - 1, g = i[0], b = i[y], w = !a; p <= v && d <= y;)t(h) ? h = r[++p] : t(m) ? m = r[--v] : ir(h, g) ? (x(h, g, o, i, d), h = r[++p], g = i[++d]) : ir(m, b) ? (x(m, b, o, i, y), m = r[--v], b = i[--y]) : ir(h, b) ? (x(h, b, o, i, y), w && u.insertBefore(e, h.elm, u.nextSibling(m.elm)), h = r[++p], b = i[--y]) : ir(m, g) ? (x(m, g, o, i, d), w && u.insertBefore(e, m.elm, h.elm), m = r[--v], g = i[++d]) : (t(s) && (s = or(r, p, v)), t(c = n(g.key) ? s[g.key] : C(g, r, p, v)) ? f(g, o, e, h.elm, !1, i, d) : ir(l = r[c], g) ? (x(l, g, o, i, d), r[c] = void 0, w && u.insertBefore(e, l.elm, h.elm)) : f(g, o, e, h.elm, !1, i, d), g = i[++d]); p > v ? _(e, t(i[y + 1]) ? null : i[y + 1].elm, i, d, y, o) : d > y && $(r, p, v) }(p, h, y, o, l) : n(y) ? (n(e.text) && u.setTextContent(p, ""), _(p, null, y, 0, y.length - 1, o)) : n(h) ? $(h, 0, h.length - 1) : n(e.text) && u.setTextContent(p, "") : e.text !== i.text && u.setTextContent(p, i.text), n(v) && n(d = v.hook) && n(d = d.postpatch) && d(e, i) } } } function k(e, t, i) { if (r(i) && n(e.parent)) e.parent.data.pendingInsert = t; else for (var o = 0; o < t.length; ++o)t[o].data.hook.insert(t[o]) } var A = p("attrs,class,staticClass,staticStyle,key"); function O(e, t, i, o) { var a, s = t.tag, c = t.data, u = t.children; if (o = o || c && c.pre, t.elm = e, r(t.isComment) && n(t.asyncFactory)) return t.isAsyncPlaceholder = !0, !0; if (n(c) && (n(a = c.hook) && n(a = a.init) && a(t, !0), n(a = t.componentInstance))) return d(t, i), !0; if (n(s)) { if (n(u)) if (e.hasChildNodes()) if (n(a = c) && n(a = a.domProps) && n(a = a.innerHTML)) { if (a !== e.innerHTML) return !1 } else { for (var l = !0, f = e.firstChild, p = 0; p < u.length; p++){ if (!f || !O(f, u[p], i, o)) { l = !1; break } f = f.nextSibling } if (!l || f) return !1 } else h(t, u, i); if (n(c)) { var v = !1; for (var m in c) if (!A(m)) { v = !0, y(t, i); break } !v && c.class && et(c.class) } } else e.data !== t.text && (e.data = t.text); return !0 } return function (e, i, o, a) { if (!t(i)) { var c, l = !1, p = []; if (t(e)) l = !0, f(i, p); else { var d = n(e.nodeType); if (!d && ir(e, i)) x(e, i, p, null, null, a); else { if (d) { if (1 === e.nodeType && e.hasAttribute(L) && (e.removeAttribute(L), o = !0), r(o) && O(e, i, p)) return k(i, p, !0), e; c = e, e = new pe(u.tagName(c).toLowerCase(), {}, [], void 0, c) } var v = e.elm, h = u.parentNode(v); if (f(i, p, v._leaveCb ? null : h, u.nextSibling(v)), n(i.parent)) for (var y = i.parent, g = m(i); y;){ for (var _ = 0; _ < s.destroy.length; ++_)s.destroy[_](y); if (y.elm = i.elm, g) { for (var w = 0; w < s.create.length; ++w)s.create[w](nr, y); var C = y.data.hook.insert; if (C.merged) for (var A = 1; A < C.fns.length; A++)C.fns[A]() } else tr(y); y = y.parent } n(h) ? $([e], 0, 0) : n(e.tag) && b(e) } } return k(i, p, l), i.elm } n(e) && b(e) } }({ nodeOps: Qn, modules: [mr, xr, ni, oi, mi, z ? { create: Ui, activate: Ui, remove: function (e, t) { !0 !== e.data.show ? Ri(e, t) : t() } } : {}].concat(pr) }); W && document.addEventListener("selectionchange", function () { var e = document.activeElement; e && e.vmodel && Xi(e, "input") }); var Vi = { inserted: function (e, t, n, r) { "select" === n.tag ? (r.elm && !r.elm._vOptions ? it(n, "postpatch", function () { Vi.componentUpdated(e, t, n) }) : Ki(e, t, n.context), e._vOptions = [].map.call(e.options, Wi)) : ("textarea" === n.tag || Xn(e.type)) && (e._vModifiers = t.modifiers, t.modifiers.lazy || (e.addEventListener("compositionstart", Zi), e.addEventListener("compositionend", Gi), e.addEventListener("change", Gi), W && (e.vmodel = !0))) }, componentUpdated: function (e, t, n) { if ("select" === n.tag) { Ki(e, t, n.context); var r = e._vOptions, i = e._vOptions = [].map.call(e.options, Wi); if (i.some(function (e, t) { return !N(e, r[t]) })) (e.multiple ? t.value.some(function (e) { return qi(e, i) }) : t.value !== t.oldValue && qi(t.value, i)) && Xi(e, "change") } } }; function Ki(e, t, n) { Ji(e, t, n), (q || Z) && setTimeout(function () { Ji(e, t, n) }, 0) } function Ji(e, t, n) { var r = t.value, i = e.multiple; if (!i || Array.isArray(r)) { for (var o, a, s = 0, c = e.options.length; s < c; s++)if (a = e.options[s], i) o = j(r, Wi(a)) > -1, a.selected !== o && (a.selected = o); else if (N(Wi(a), r)) return void (e.selectedIndex !== s && (e.selectedIndex = s)); i || (e.selectedIndex = -1) } } function qi(e, t) { return t.every(function (t) { return !N(t, e) }) } function Wi(e) { return "_value" in e ? e._value : e.value } function Zi(e) { e.target.composing = !0 } function Gi(e) { e.target.composing && (e.target.composing = !1, Xi(e.target, "input")) } function Xi(e, t) { var n = document.createEvent("HTMLEvents"); n.initEvent(t, !0, !0), e.dispatchEvent(n) } function Yi(e) { return !e.componentInstance || e.data && e.data.transition ? e : Yi(e.componentInstance._vnode) } var Qi = { model: Vi, show: { bind: function (e, t, n) { var r = t.value, i = (n = Yi(n)).data && n.data.transition, o = e.__vOriginalDisplay = "none" === e.style.display ? "" : e.style.display; r && i ? (n.data.show = !0, Pi(n, function () { e.style.display = o })) : e.style.display = r ? o : "none" }, update: function (e, t, n) { var r = t.value; !r != !t.oldValue && ((n = Yi(n)).data && n.data.transition ? (n.data.show = !0, r ? Pi(n, function () { e.style.display = e.__vOriginalDisplay }) : Ri(n, function () { e.style.display = "none" })) : e.style.display = r ? e.__vOriginalDisplay : "none") }, unbind: function (e, t, n, r, i) { i || (e.style.display = e.__vOriginalDisplay) } } }, eo = { name: String, appear: Boolean, css: Boolean, mode: String, type: String, enterClass: String, leaveClass: String, enterToClass: String, leaveToClass: String, enterActiveClass: String, leaveActiveClass: String, appearClass: String, appearActiveClass: String, appearToClass: String, duration: [Number, String, Object] }; function to(e) { var t = e && e.componentOptions; return t && t.Ctor.options.abstract ? to(zt(t.children)) : e } function no(e) { var t = {}, n = e.$options; for (var r in n.propsData) t[r] = e[r]; var i = n._parentListeners; for (var o in i) t[b(o)] = i[o]; return t } function ro(e, t) { if (/\d-keep-alive$/.test(t.tag)) return e("keep-alive", { props: t.componentOptions.propsData }) } var io = function (e) { return e.tag || Ut(e) }, oo = function (e) { return "show" === e.name }, ao = { name: "transition", props: eo, abstract: !0, render: function (e) { var t = this, n = this.$slots.default; if (n && (n = n.filter(io)).length) { var r = this.mode, o = n[0]; if (function (e) { for (; e = e.parent;)if (e.data.transition) return !0 }(this.$vnode)) return o; var a = to(o); if (!a) return o; if (this._leaving) return ro(e, o); var s = "__transition-" + this._uid + "-"; a.key = null == a.key ? a.isComment ? s + "comment" : s + a.tag : i(a.key) ? 0 === String(a.key).indexOf(s) ? a.key : s + a.key : a.key; var c = (a.data || (a.data = {})).transition = no(this), u = this._vnode, l = to(u); if (a.data.directives && a.data.directives.some(oo) && (a.data.show = !0), l && l.data && !function (e, t) { return t.key === e.key && t.tag === e.tag }(a, l) && !Ut(l) && (!l.componentInstance || !l.componentInstance._vnode.isComment)) { var f = l.data.transition = A({}, c); if ("out-in" === r) return this._leaving = !0, it(f, "afterLeave", function () { t._leaving = !1, t.$forceUpdate() }), ro(e, o); if ("in-out" === r) { if (Ut(a)) return u; var p, d = function () { p() }; it(c, "afterEnter", d), it(c, "enterCancelled", d), it(f, "delayLeave", function (e) { p = e }) } } return o } } }, so = A({ tag: String, moveClass: String }, eo); function co(e) { e.elm._moveCb && e.elm._moveCb(), e.elm._enterCb && e.elm._enterCb() } function uo(e) { e.data.newPos = e.elm.getBoundingClientRect() } function lo(e) { var t = e.data.pos, n = e.data.newPos, r = t.left - n.left, i = t.top - n.top; if (r || i) { e.data.moved = !0; var o = e.elm.style; o.transform = o.WebkitTransform = "translate(" + r + "px," + i + "px)", o.transitionDuration = "0s" } } delete so.mode; var fo = { Transition: ao, TransitionGroup: { props: so, beforeMount: function () { var e = this, t = this._update; this._update = function (n, r) { var i = Zt(e); e.__patch__(e._vnode, e.kept, !1, !0), e._vnode = e.kept, i(), t.call(e, n, r) } }, render: function (e) { for (var t = this.tag || this.$vnode.data.tag || "span", n = Object.create(null), r = this.prevChildren = this.children, i = this.$slots.default || [], o = this.children = [], a = no(this), s = 0; s < i.length; s++){ var c = i[s]; c.tag && null != c.key && 0 !== String(c.key).indexOf("__vlist") && (o.push(c), n[c.key] = c, (c.data || (c.data = {})).transition = a) } if (r) { for (var u = [], l = [], f = 0; f < r.length; f++){ var p = r[f]; p.data.transition = a, p.data.pos = p.elm.getBoundingClientRect(), n[p.key] ? u.push(p) : l.push(p) } this.kept = e(t, null, u), this.removed = l } return e(t, null, o) }, updated: function () { var e = this.prevChildren, t = this.moveClass || (this.name || "v") + "-move"; e.length && this.hasMove(e[0].elm, t) && (e.forEach(co), e.forEach(uo), e.forEach(lo), this._reflow = document.body.offsetHeight, e.forEach(function (e) { if (e.data.moved) { var n = e.elm, r = n.style; Ni(n, t), r.transform = r.WebkitTransform = r.transitionDuration = "", n.addEventListener(Ai, n._moveCb = function e(r) { r && r.target !== n || r && !/transform$/.test(r.propertyName) || (n.removeEventListener(Ai, e), n._moveCb = null, ji(n, t)) }) } })) }, methods: { hasMove: function (e, t) { if (!wi) return !1; if (this._hasMove) return this._hasMove; var n = e.cloneNode(); e._transitionClasses && e._transitionClasses.forEach(function (e) { _i(n, e) }), gi(n, t), n.style.display = "none", this.$el.appendChild(n); var r = Mi(n); return this.$el.removeChild(n), this._hasMove = r.hasTransform } } } }; wn.config.mustUseProp = jn, wn.config.isReservedTag = Wn, wn.config.isReservedAttr = En, wn.config.getTagNamespace = Zn, wn.config.isUnknownElement = function (e) { if (!z) return !0; if (Wn(e)) return !1; if (e = e.toLowerCase(), null != Gn[e]) return Gn[e]; var t = document.createElement(e); return e.indexOf("-") > -1 ? Gn[e] = t.constructor === window.HTMLUnknownElement || t.constructor === window.HTMLElement : Gn[e] = /HTMLUnknownElement/.test(t.toString()) }, A(wn.options.directives, Qi), A(wn.options.components, fo), wn.prototype.__patch__ = z ? zi : S, wn.prototype.$mount = function (e, t) { return function (e, t, n) { var r; return e.$el = t, e.$options.render || (e.$options.render = ve), Yt(e, "beforeMount"), r = function () { e._update(e._render(), n) }, new fn(e, r, S, { before: function () { e._isMounted && !e._isDestroyed && Yt(e, "beforeUpdate") } }, !0), n = !1, null == e.$vnode && (e._isMounted = !0, Yt(e, "mounted")), e }(this, e = e && z ? Yn(e) : void 0, t) }, z && setTimeout(function () { F.devtools && ne && ne.emit("init", wn) }, 0); var po = /\{\{((?:.|\r?\n)+?)\}\}/g, vo = /[-.*+?^${}()|[\]\/\\]/g, ho = g(function (e) { var t = e[0].replace(vo, "\\$&"), n = e[1].replace(vo, "\\$&"); return new RegExp(t + "((?:.|\\n)+?)" + n, "g") }); var mo = { staticKeys: ["staticClass"], transformNode: function (e, t) { t.warn; var n = Fr(e, "class"); n && (e.staticClass = JSON.stringify(n)); var r = Ir(e, "class", !1); r && (e.classBinding = r) }, genData: function (e) { var t = ""; return e.staticClass && (t += "staticClass:" + e.staticClass + ","), e.classBinding && (t += "class:" + e.classBinding + ","), t } }; var yo, go = { staticKeys: ["staticStyle"], transformNode: function (e, t) { t.warn; var n = Fr(e, "style"); n && (e.staticStyle = JSON.stringify(ai(n))); var r = Ir(e, "style", !1); r && (e.styleBinding = r) }, genData: function (e) { var t = ""; return e.staticStyle && (t += "staticStyle:" + e.staticStyle + ","), e.styleBinding && (t += "style:(" + e.styleBinding + "),"), t } }, _o = function (e) { return (yo = yo || document.createElement("div")).innerHTML = e, yo.textContent }, bo = p("area,base,br,col,embed,frame,hr,img,input,isindex,keygen,link,meta,param,source,track,wbr"), $o = p("colgroup,dd,dt,li,options,p,td,tfoot,th,thead,tr,source"), wo = p("address,article,aside,base,blockquote,body,caption,col,colgroup,dd,details,dialog,div,dl,dt,fieldset,figcaption,figure,footer,form,h1,h2,h3,h4,h5,h6,head,header,hgroup,hr,html,legend,li,menuitem,meta,optgroup,option,param,rp,rt,source,style,summary,tbody,td,tfoot,th,thead,title,tr,track"), Co = /^\s*([^\s"'<>\/=]+)(?:\s*(=)\s*(?:"([^"]*)"+|'([^']*)'+|([^\s"'=<>`]+)))?/, xo = /^\s*((?:v-[\w-]+:|@|:|#)\[[^=]+\][^\s"'<>\/=]*)(?:\s*(=)\s*(?:"([^"]*)"+|'([^']*)'+|([^\s"'=<>`]+)))?/, ko = "[a-zA-Z_][\\-\\.0-9_a-zA-Z" + P.source + "]*", Ao = "((?:" + ko + "\\:)?" + ko + ")", Oo = new RegExp("^<" + Ao), So = /^\s*(\/?)>/, To = new RegExp("^<\\/" + Ao + "[^>]*>"), Eo = /^<!DOCTYPE [^>]+>/i, No = /^<!\--/, jo = /^<!\[/, Do = p("script,style,textarea", !0), Lo = {}, Mo = { "&lt;": "<", "&gt;": ">", "&quot;": '"', "&amp;": "&", "&#10;": "\n", "&#9;": "\t", "&#39;": "'" }, Io = /&(?:lt|gt|quot|amp|#39);/g, Fo = /&(?:lt|gt|quot|amp|#39|#10|#9);/g, Po = p("pre,textarea", !0), Ro = function (e, t) { return e && Po(e) && "\n" === t[0] }; function Ho(e, t) { var n = t ? Fo : Io; return e.replace(n, function (e) { return Mo[e] }) } var Bo, Uo, zo, Vo, Ko, Jo, qo, Wo, Zo = /^@|^v-on:/, Go = /^v-|^@|^:|^#/, Xo = /([\s\S]*?)\s+(?:in|of)\s+([\s\S]*)/, Yo = /,([^,\}\]]*)(?:,([^,\}\]]*))?$/, Qo = /^\(|\)$/g, ea = /^\[.*\]$/, ta = /:(.*)$/, na = /^:|^\.|^v-bind:/, ra = /\.[^.\]]+(?=[^\]]*$)/g, ia = /^v-slot(:|$)|^#/, oa = /[\r\n]/, aa = /\s+/g, sa = g(_o), ca = "_empty_"; function ua(e, t, n) { return { type: 1, tag: e, attrsList: t, attrsMap: ma(t), rawAttrsMap: {}, parent: n, children: [] } } function la(e, t) { Bo = t.warn || Sr, Jo = t.isPreTag || T, qo = t.mustUseProp || T, Wo = t.getTagNamespace || T; t.isReservedTag; zo = Tr(t.modules, "transformNode"), Vo = Tr(t.modules, "preTransformNode"), Ko = Tr(t.modules, "postTransformNode"), Uo = t.delimiters; var n, r, i = [], o = !1 !== t.preserveWhitespace, a = t.whitespace, s = !1, c = !1; function u(e) { if (l(e), s || e.processed || (e = fa(e, t)), i.length || e === n || n.if && (e.elseif || e.else) && da(n, { exp: e.elseif, block: e }), r && !e.forbidden) if (e.elseif || e.else) a = e, (u = function (e) { var t = e.length; for (; t--;){ if (1 === e[t].type) return e[t]; e.pop() } }(r.children)) && u.if && da(u, { exp: a.elseif, block: a }); else { if (e.slotScope) { var o = e.slotTarget || '"default"'; (r.scopedSlots || (r.scopedSlots = {}))[o] = e } r.children.push(e), e.parent = r } var a, u; e.children = e.children.filter(function (e) { return !e.slotScope }), l(e), e.pre && (s = !1), Jo(e.tag) && (c = !1); for (var f = 0; f < Ko.length; f++)Ko[f](e, t) } function l(e) { if (!c) for (var t; (t = e.children[e.children.length - 1]) && 3 === t.type && " " === t.text;)e.children.pop() } return function (e, t) { for (var n, r, i = [], o = t.expectHTML, a = t.isUnaryTag || T, s = t.canBeLeftOpenTag || T, c = 0; e;){ if (n = e, r && Do(r)) { var u = 0, l = r.toLowerCase(), f = Lo[l] || (Lo[l] = new RegExp("([\\s\\S]*?)(</" + l + "[^>]*>)", "i")), p = e.replace(f, function (e, n, r) { return u = r.length, Do(l) || "noscript" === l || (n = n.replace(/<!\--([\s\S]*?)-->/g, "$1").replace(/<!\[CDATA\[([\s\S]*?)]]>/g, "$1")), Ro(l, n) && (n = n.slice(1)), t.chars && t.chars(n), "" }); c += e.length - p.length, e = p, A(l, c - u, c) } else { var d = e.indexOf("<"); if (0 === d) { if (No.test(e)) { var v = e.indexOf("--\x3e"); if (v >= 0) { t.shouldKeepComment && t.comment(e.substring(4, v), c, c + v + 3), C(v + 3); continue } } if (jo.test(e)) { var h = e.indexOf("]>"); if (h >= 0) { C(h + 2); continue } } var m = e.match(Eo); if (m) { C(m[0].length); continue } var y = e.match(To); if (y) { var g = c; C(y[0].length), A(y[1], g, c); continue } var _ = x(); if (_) { k(_), Ro(_.tagName, e) && C(1); continue } } var b = void 0, $ = void 0, w = void 0; if (d >= 0) { for ($ = e.slice(d); !(To.test($) || Oo.test($) || No.test($) || jo.test($) || (w = $.indexOf("<", 1)) < 0);)d += w, $ = e.slice(d); b = e.substring(0, d) } d < 0 && (b = e), b && C(b.length), t.chars && b && t.chars(b, c - b.length, c) } if (e === n) { t.chars && t.chars(e); break } } function C(t) { c += t, e = e.substring(t) } function x() { var t = e.match(Oo); if (t) { var n, r, i = { tagName: t[1], attrs: [], start: c }; for (C(t[0].length); !(n = e.match(So)) && (r = e.match(xo) || e.match(Co));)r.start = c, C(r[0].length), r.end = c, i.attrs.push(r); if (n) return i.unarySlash = n[1], C(n[0].length), i.end = c, i } } function k(e) { var n = e.tagName, c = e.unarySlash; o && ("p" === r && wo(n) && A(r), s(n) && r === n && A(n)); for (var u = a(n) || !!c, l = e.attrs.length, f = new Array(l), p = 0; p < l; p++){ var d = e.attrs[p], v = d[3] || d[4] || d[5] || "", h = "a" === n && "href" === d[1] ? t.shouldDecodeNewlinesForHref : t.shouldDecodeNewlines; f[p] = { name: d[1], value: Ho(v, h) } } u || (i.push({ tag: n, lowerCasedTag: n.toLowerCase(), attrs: f, start: e.start, end: e.end }), r = n), t.start && t.start(n, f, u, e.start, e.end) } function A(e, n, o) { var a, s; if (null == n && (n = c), null == o && (o = c), e) for (s = e.toLowerCase(), a = i.length - 1; a >= 0 && i[a].lowerCasedTag !== s; a--); else a = 0; if (a >= 0) { for (var u = i.length - 1; u >= a; u--)t.end && t.end(i[u].tag, n, o); i.length = a, r = a && i[a - 1].tag } else "br" === s ? t.start && t.start(e, [], !0, n, o) : "p" === s && (t.start && t.start(e, [], !1, n, o), t.end && t.end(e, n, o)) } A() }(e, { warn: Bo, expectHTML: t.expectHTML, isUnaryTag: t.isUnaryTag, canBeLeftOpenTag: t.canBeLeftOpenTag, shouldDecodeNewlines: t.shouldDecodeNewlines, shouldDecodeNewlinesForHref: t.shouldDecodeNewlinesForHref, shouldKeepComment: t.comments, outputSourceRange: t.outputSourceRange, start: function (e, o, a, l, f) { var p = r && r.ns || Wo(e); q && "svg" === p && (o = function (e) { for (var t = [], n = 0; n < e.length; n++){ var r = e[n]; ya.test(r.name) || (r.name = r.name.replace(ga, ""), t.push(r)) } return t }(o)); var d, v = ua(e, o, r); p && (v.ns = p), "style" !== (d = v).tag && ("script" !== d.tag || d.attrsMap.type && "text/javascript" !== d.attrsMap.type) || te() || (v.forbidden = !0); for (var h = 0; h < Vo.length; h++)v = Vo[h](v, t) || v; s || (!function (e) { null != Fr(e, "v-pre") && (e.pre = !0) }(v), v.pre && (s = !0)), Jo(v.tag) && (c = !0), s ? function (e) { var t = e.attrsList, n = t.length; if (n) for (var r = e.attrs = new Array(n), i = 0; i < n; i++)r[i] = { name: t[i].name, value: JSON.stringify(t[i].value) }, null != t[i].start && (r[i].start = t[i].start, r[i].end = t[i].end); else e.pre || (e.plain = !0) }(v) : v.processed || (pa(v), function (e) { var t = Fr(e, "v-if"); if (t) e.if = t, da(e, { exp: t, block: e }); else { null != Fr(e, "v-else") && (e.else = !0); var n = Fr(e, "v-else-if"); n && (e.elseif = n) } }(v), function (e) { null != Fr(e, "v-once") && (e.once = !0) }(v)), n || (n = v), a ? u(v) : (r = v, i.push(v)) }, end: function (e, t, n) { var o = i[i.length - 1]; i.length -= 1, r = i[i.length - 1], u(o) }, chars: function (e, t, n) { if (r && (!q || "textarea" !== r.tag || r.attrsMap.placeholder !== e)) { var i, u, l, f = r.children; if (e = c || e.trim() ? "script" === (i = r).tag || "style" === i.tag ? e : sa(e) : f.length ? a ? "condense" === a && oa.test(e) ? "" : " " : o ? " " : "" : "") c || "condense" !== a || (e = e.replace(aa, " ")), !s && " " !== e && (u = function (e, t) { var n = t ? ho(t) : po; if (n.test(e)) { for (var r, i, o, a = [], s = [], c = n.lastIndex = 0; r = n.exec(e);){ (i = r.index) > c && (s.push(o = e.slice(c, i)), a.push(JSON.stringify(o))); var u = Ar(r[1].trim()); a.push("_s(" + u + ")"), s.push({ "@binding": u }), c = i + r[0].length } return c < e.length && (s.push(o = e.slice(c)), a.push(JSON.stringify(o))), { expression: a.join("+"), tokens: s } } }(e, Uo)) ? l = { type: 2, expression: u.expression, tokens: u.tokens, text: e } : " " === e && f.length && " " === f[f.length - 1].text || (l = { type: 3, text: e }), l && f.push(l) } }, comment: function (e, t, n) { if (r) { var i = { type: 3, text: e, isComment: !0 }; r.children.push(i) } } }), n } function fa(e, t) { var n, r; (r = Ir(n = e, "key")) && (n.key = r), e.plain = !e.key && !e.scopedSlots && !e.attrsList.length, function (e) { var t = Ir(e, "ref"); t && (e.ref = t, e.refInFor = function (e) { var t = e; for (; t;){ if (void 0 !== t.for) return !0; t = t.parent } return !1 }(e)) }(e), function (e) { var t; "template" === e.tag ? (t = Fr(e, "scope"), e.slotScope = t || Fr(e, "slot-scope")) : (t = Fr(e, "slot-scope")) && (e.slotScope = t); var n = Ir(e, "slot"); n && (e.slotTarget = '""' === n ? '"default"' : n, e.slotTargetDynamic = !(!e.attrsMap[":slot"] && !e.attrsMap["v-bind:slot"]), "template" === e.tag || e.slotScope || Nr(e, "slot", n, function (e, t) { return e.rawAttrsMap[":" + t] || e.rawAttrsMap["v-bind:" + t] || e.rawAttrsMap[t] }(e, "slot"))); if ("template" === e.tag) { var r = Pr(e, ia); if (r) { var i = va(r), o = i.name, a = i.dynamic; e.slotTarget = o, e.slotTargetDynamic = a, e.slotScope = r.value || ca } } else { var s = Pr(e, ia); if (s) { var c = e.scopedSlots || (e.scopedSlots = {}), u = va(s), l = u.name, f = u.dynamic, p = c[l] = ua("template", [], e); p.slotTarget = l, p.slotTargetDynamic = f, p.children = e.children.filter(function (e) { if (!e.slotScope) return e.parent = p, !0 }), p.slotScope = s.value || ca, e.children = [], e.plain = !1 } } }(e), function (e) { "slot" === e.tag && (e.slotName = Ir(e, "name")) }(e), function (e) { var t; (t = Ir(e, "is")) && (e.component = t); null != Fr(e, "inline-template") && (e.inlineTemplate = !0) }(e); for (var i = 0; i < zo.length; i++)e = zo[i](e, t) || e; return function (e) { var t, n, r, i, o, a, s, c, u = e.attrsList; for (t = 0, n = u.length; t < n; t++)if (r = i = u[t].name, o = u[t].value, Go.test(r)) if (e.hasBindings = !0, (a = ha(r.replace(Go, ""))) && (r = r.replace(ra, "")), na.test(r)) r = r.replace(na, ""), o = Ar(o), (c = ea.test(r)) && (r = r.slice(1, -1)), a && (a.prop && !c && "innerHtml" === (r = b(r)) && (r = "innerHTML"), a.camel && !c && (r = b(r)), a.sync && (s = Br(o, "$event"), c ? Mr(e, '"update:"+(' + r + ")", s, null, !1, 0, u[t], !0) : (Mr(e, "update:" + b(r), s, null, !1, 0, u[t]), C(r) !== b(r) && Mr(e, "update:" + C(r), s, null, !1, 0, u[t])))), a && a.prop || !e.component && qo(e.tag, e.attrsMap.type, r) ? Er(e, r, o, u[t], c) : Nr(e, r, o, u[t], c); else if (Zo.test(r)) r = r.replace(Zo, ""), (c = ea.test(r)) && (r = r.slice(1, -1)), Mr(e, r, o, a, !1, 0, u[t], c); else { var l = (r = r.replace(Go, "")).match(ta), f = l && l[1]; c = !1, f && (r = r.slice(0, -(f.length + 1)), ea.test(f) && (f = f.slice(1, -1), c = !0)), Dr(e, r, i, o, f, c, a, u[t]) } else Nr(e, r, JSON.stringify(o), u[t]), !e.component && "muted" === r && qo(e.tag, e.attrsMap.type, r) && Er(e, r, "true", u[t]) }(e), e } function pa(e) { var t; if (t = Fr(e, "v-for")) { var n = function (e) { var t = e.match(Xo); if (!t) return; var n = {}; n.for = t[2].trim(); var r = t[1].trim().replace(Qo, ""), i = r.match(Yo); i ? (n.alias = r.replace(Yo, "").trim(), n.iterator1 = i[1].trim(), i[2] && (n.iterator2 = i[2].trim())) : n.alias = r; return n }(t); n && A(e, n) } } function da(e, t) { e.ifConditions || (e.ifConditions = []), e.ifConditions.push(t) } function va(e) { var t = e.name.replace(ia, ""); return t || "#" !== e.name[0] && (t = "default"), ea.test(t) ? { name: t.slice(1, -1), dynamic: !0 } : { name: '"' + t + '"', dynamic: !1 } } function ha(e) { var t = e.match(ra); if (t) { var n = {}; return t.forEach(function (e) { n[e.slice(1)] = !0 }), n } } function ma(e) { for (var t = {}, n = 0, r = e.length; n < r; n++)t[e[n].name] = e[n].value; return t } var ya = /^xmlns:NS\d+/, ga = /^NS\d+:/; function _a(e) { return ua(e.tag, e.attrsList.slice(), e.parent) } var ba = [mo, go, { preTransformNode: function (e, t) { if ("input" === e.tag) { var n, r = e.attrsMap; if (!r["v-model"]) return; if ((r[":type"] || r["v-bind:type"]) && (n = Ir(e, "type")), r.type || n || !r["v-bind"] || (n = "(" + r["v-bind"] + ").type"), n) { var i = Fr(e, "v-if", !0), o = i ? "&&(" + i + ")" : "", a = null != Fr(e, "v-else", !0), s = Fr(e, "v-else-if", !0), c = _a(e); pa(c), jr(c, "type", "checkbox"), fa(c, t), c.processed = !0, c.if = "(" + n + ")==='checkbox'" + o, da(c, { exp: c.if, block: c }); var u = _a(e); Fr(u, "v-for", !0), jr(u, "type", "radio"), fa(u, t), da(c, { exp: "(" + n + ")==='radio'" + o, block: u }); var l = _a(e); return Fr(l, "v-for", !0), jr(l, ":type", n), fa(l, t), da(c, { exp: i, block: l }), a ? c.else = !0 : s && (c.elseif = s), c } } } }]; var $a, wa, Ca = { expectHTML: !0, modules: ba, directives: { model: function (e, t, n) { var r = t.value, i = t.modifiers, o = e.tag, a = e.attrsMap.type; if (e.component) return Hr(e, r, i), !1; if ("select" === o) !function (e, t, n) { var r = 'var $$selectedVal = Array.prototype.filter.call($event.target.options,function(o){return o.selected}).map(function(o){var val = "_value" in o ? o._value : o.value;return ' + (n && n.number ? "_n(val)" : "val") + "});"; r = r + " " + Br(t, "$event.target.multiple ? $$selectedVal : $$selectedVal[0]"), Mr(e, "change", r, null, !0) }(e, r, i); else if ("input" === o && "checkbox" === a) !function (e, t, n) { var r = n && n.number, i = Ir(e, "value") || "null", o = Ir(e, "true-value") || "true", a = Ir(e, "false-value") || "false"; Er(e, "checked", "Array.isArray(" + t + ")?_i(" + t + "," + i + ")>-1" + ("true" === o ? ":(" + t + ")" : ":_q(" + t + "," + o + ")")), Mr(e, "change", "var $$a=" + t + ",$$el=$event.target,$$c=$$el.checked?(" + o + "):(" + a + ");if(Array.isArray($$a)){var $$v=" + (r ? "_n(" + i + ")" : i) + ",$$i=_i($$a,$$v);if($$el.checked){$$i<0&&(" + Br(t, "$$a.concat([$$v])") + ")}else{$$i>-1&&(" + Br(t, "$$a.slice(0,$$i).concat($$a.slice($$i+1))") + ")}}else{" + Br(t, "$$c") + "}", null, !0) }(e, r, i); else if ("input" === o && "radio" === a) !function (e, t, n) { var r = n && n.number, i = Ir(e, "value") || "null"; Er(e, "checked", "_q(" + t + "," + (i = r ? "_n(" + i + ")" : i) + ")"), Mr(e, "change", Br(t, i), null, !0) }(e, r, i); else if ("input" === o || "textarea" === o) !function (e, t, n) { var r = e.attrsMap.type, i = n || {}, o = i.lazy, a = i.number, s = i.trim, c = !o && "range" !== r, u = o ? "change" : "range" === r ? Wr : "input", l = "$event.target.value"; s && (l = "$event.target.value.trim()"), a && (l = "_n(" + l + ")"); var f = Br(t, l); c && (f = "if($event.target.composing)return;" + f), Er(e, "value", "(" + t + ")"), Mr(e, u, f, null, !0), (s || a) && Mr(e, "blur", "$forceUpdate()") }(e, r, i); else if (!F.isReservedTag(o)) return Hr(e, r, i), !1; return !0 }, text: function (e, t) { t.value && Er(e, "textContent", "_s(" + t.value + ")", t) }, html: function (e, t) { t.value && Er(e, "innerHTML", "_s(" + t.value + ")", t) } }, isPreTag: function (e) { return "pre" === e }, isUnaryTag: bo, mustUseProp: jn, canBeLeftOpenTag: $o, isReservedTag: Wn, getTagNamespace: Zn, staticKeys: function (e) { return e.reduce(function (e, t) { return e.concat(t.staticKeys || []) }, []).join(",") }(ba) }, xa = g(function (e) { return p("type,tag,attrsList,attrsMap,plain,parent,children,attrs,start,end,rawAttrsMap" + (e ? "," + e : "")) }); function ka(e, t) { e && ($a = xa(t.staticKeys || ""), wa = t.isReservedTag || T, function e(t) { t.static = function (e) { if (2 === e.type) return !1; if (3 === e.type) return !0; return !(!e.pre && (e.hasBindings || e.if || e.for || d(e.tag) || !wa(e.tag) || function (e) { for (; e.parent;){ if ("template" !== (e = e.parent).tag) return !1; if (e.for) return !0 } return !1 }(e) || !Object.keys(e).every($a))) }(t); if (1 === t.type) { if (!wa(t.tag) && "slot" !== t.tag && null == t.attrsMap["inline-template"]) return; for (var n = 0, r = t.children.length; n < r; n++){ var i = t.children[n]; e(i), i.static || (t.static = !1) } if (t.ifConditions) for (var o = 1, a = t.ifConditions.length; o < a; o++){ var s = t.ifConditions[o].block; e(s), s.static || (t.static = !1) } } }(e), function e(t, n) { if (1 === t.type) { if ((t.static || t.once) && (t.staticInFor = n), t.static && t.children.length && (1 !== t.children.length || 3 !== t.children[0].type)) return void (t.staticRoot = !0); if (t.staticRoot = !1, t.children) for (var r = 0, i = t.children.length; r < i; r++)e(t.children[r], n || !!t.for); if (t.ifConditions) for (var o = 1, a = t.ifConditions.length; o < a; o++)e(t.ifConditions[o].block, n) } }(e, !1)) } var Aa = /^([\w$_]+|\([^)]*?\))\s*=>|^function(?:\s+[\w$]+)?\s*\(/, Oa = /\([^)]*?\);*$/, Sa = /^[A-Za-z_$][\w$]*(?:\.[A-Za-z_$][\w$]*|\['[^']*?']|\["[^"]*?"]|\[\d+]|\[[A-Za-z_$][\w$]*])*$/, Ta = { esc: 27, tab: 9, enter: 13, space: 32, up: 38, left: 37, right: 39, down: 40, delete: [8, 46] }, Ea = { esc: ["Esc", "Escape"], tab: "Tab", enter: "Enter", space: [" ", "Spacebar"], up: ["Up", "ArrowUp"], left: ["Left", "ArrowLeft"], right: ["Right", "ArrowRight"], down: ["Down", "ArrowDown"], delete: ["Backspace", "Delete", "Del"] }, Na = function (e) { return "if(" + e + ")return null;" }, ja = { stop: "$event.stopPropagation();", prevent: "$event.preventDefault();", self: Na("$event.target !== $event.currentTarget"), ctrl: Na("!$event.ctrlKey"), shift: Na("!$event.shiftKey"), alt: Na("!$event.altKey"), meta: Na("!$event.metaKey"), left: Na("'button' in $event && $event.button !== 0"), middle: Na("'button' in $event && $event.button !== 1"), right: Na("'button' in $event && $event.button !== 2") }; function Da(e, t) { var n = t ? "nativeOn:" : "on:", r = "", i = ""; for (var o in e) { var a = La(e[o]); e[o] && e[o].dynamic ? i += o + "," + a + "," : r += '"' + o + '":' + a + "," } return r = "{" + r.slice(0, -1) + "}", i ? n + "_d(" + r + ",[" + i.slice(0, -1) + "])" : n + r } function La(e) { if (!e) return "function(){}"; if (Array.isArray(e)) return "[" + e.map(function (e) { return La(e) }).join(",") + "]"; var t = Sa.test(e.value), n = Aa.test(e.value), r = Sa.test(e.value.replace(Oa, "")); if (e.modifiers) { var i = "", o = "", a = []; for (var s in e.modifiers) if (ja[s]) o += ja[s], Ta[s] && a.push(s); else if ("exact" === s) { var c = e.modifiers; o += Na(["ctrl", "shift", "alt", "meta"].filter(function (e) { return !c[e] }).map(function (e) { return "$event." + e + "Key" }).join("||")) } else a.push(s); return a.length && (i += function (e) { return "if(!$event.type.indexOf('key')&&" + e.map(Ma).join("&&") + ")return null;" }(a)), o && (i += o), "function($event){" + i + (t ? "return " + e.value + "($event)" : n ? "return (" + e.value + ")($event)" : r ? "return " + e.value : e.value) + "}" } return t || n ? e.value : "function($event){" + (r ? "return " + e.value : e.value) + "}" } function Ma(e) { var t = parseInt(e, 10); if (t) return "$event.keyCode!==" + t; var n = Ta[e], r = Ea[e]; return "_k($event.keyCode," + JSON.stringify(e) + "," + JSON.stringify(n) + ",$event.key," + JSON.stringify(r) + ")" } var Ia = { on: function (e, t) { e.wrapListeners = function (e) { return "_g(" + e + "," + t.value + ")" } }, bind: function (e, t) { e.wrapData = function (n) { return "_b(" + n + ",'" + e.tag + "'," + t.value + "," + (t.modifiers && t.modifiers.prop ? "true" : "false") + (t.modifiers && t.modifiers.sync ? ",true" : "") + ")" } }, cloak: S }, Fa = function (e) { this.options = e, this.warn = e.warn || Sr, this.transforms = Tr(e.modules, "transformCode"), this.dataGenFns = Tr(e.modules, "genData"), this.directives = A(A({}, Ia), e.directives); var t = e.isReservedTag || T; this.maybeComponent = function (e) { return !!e.component || !t(e.tag) }, this.onceId = 0, this.staticRenderFns = [], this.pre = !1 }; function Pa(e, t) { var n = new Fa(t); return { render: "with(this){return " + (e ? Ra(e, n) : '_c("div")') + "}", staticRenderFns: n.staticRenderFns } } function Ra(e, t) { if (e.parent && (e.pre = e.pre || e.parent.pre), e.staticRoot && !e.staticProcessed) return Ha(e, t); if (e.once && !e.onceProcessed) return Ba(e, t); if (e.for && !e.forProcessed) return za(e, t); if (e.if && !e.ifProcessed) return Ua(e, t); if ("template" !== e.tag || e.slotTarget || t.pre) { if ("slot" === e.tag) return function (e, t) { var n = e.slotName || '"default"', r = qa(e, t), i = "_t(" + n + (r ? "," + r : ""), o = e.attrs || e.dynamicAttrs ? Ga((e.attrs || []).concat(e.dynamicAttrs || []).map(function (e) { return { name: b(e.name), value: e.value, dynamic: e.dynamic } })) : null, a = e.attrsMap["v-bind"]; !o && !a || r || (i += ",null"); o && (i += "," + o); a && (i += (o ? "" : ",null") + "," + a); return i + ")" }(e, t); var n; if (e.component) n = function (e, t, n) { var r = t.inlineTemplate ? null : qa(t, n, !0); return "_c(" + e + "," + Va(t, n) + (r ? "," + r : "") + ")" }(e.component, e, t); else { var r; (!e.plain || e.pre && t.maybeComponent(e)) && (r = Va(e, t)); var i = e.inlineTemplate ? null : qa(e, t, !0); n = "_c('" + e.tag + "'" + (r ? "," + r : "") + (i ? "," + i : "") + ")" } for (var o = 0; o < t.transforms.length; o++)n = t.transforms[o](e, n); return n } return qa(e, t) || "void 0" } function Ha(e, t) { e.staticProcessed = !0; var n = t.pre; return e.pre && (t.pre = e.pre), t.staticRenderFns.push("with(this){return " + Ra(e, t) + "}"), t.pre = n, "_m(" + (t.staticRenderFns.length - 1) + (e.staticInFor ? ",true" : "") + ")" } function Ba(e, t) { if (e.onceProcessed = !0, e.if && !e.ifProcessed) return Ua(e, t); if (e.staticInFor) { for (var n = "", r = e.parent; r;){ if (r.for) { n = r.key; break } r = r.parent } return n ? "_o(" + Ra(e, t) + "," + t.onceId++ + "," + n + ")" : Ra(e, t) } return Ha(e, t) } function Ua(e, t, n, r) { return e.ifProcessed = !0, function e(t, n, r, i) { if (!t.length) return i || "_e()"; var o = t.shift(); return o.exp ? "(" + o.exp + ")?" + a(o.block) + ":" + e(t, n, r, i) : "" + a(o.block); function a(e) { return r ? r(e, n) : e.once ? Ba(e, n) : Ra(e, n) } }(e.ifConditions.slice(), t, n, r) } function za(e, t, n, r) { var i = e.for, o = e.alias, a = e.iterator1 ? "," + e.iterator1 : "", s = e.iterator2 ? "," + e.iterator2 : ""; return e.forProcessed = !0, (r || "_l") + "((" + i + "),function(" + o + a + s + "){return " + (n || Ra)(e, t) + "})" } function Va(e, t) { var n = "{", r = function (e, t) { var n = e.directives; if (!n) return; var r, i, o, a, s = "directives:[", c = !1; for (r = 0, i = n.length; r < i; r++){ o = n[r], a = !0; var u = t.directives[o.name]; u && (a = !!u(e, o, t.warn)), a && (c = !0, s += '{name:"' + o.name + '",rawName:"' + o.rawName + '"' + (o.value ? ",value:(" + o.value + "),expression:" + JSON.stringify(o.value) : "") + (o.arg ? ",arg:" + (o.isDynamicArg ? o.arg : '"' + o.arg + '"') : "") + (o.modifiers ? ",modifiers:" + JSON.stringify(o.modifiers) : "") + "},") } if (c) return s.slice(0, -1) + "]" }(e, t); r && (n += r + ","), e.key && (n += "key:" + e.key + ","), e.ref && (n += "ref:" + e.ref + ","), e.refInFor && (n += "refInFor:true,"), e.pre && (n += "pre:true,"), e.component && (n += 'tag:"' + e.tag + '",'); for (var i = 0; i < t.dataGenFns.length; i++)n += t.dataGenFns[i](e); if (e.attrs && (n += "attrs:" + Ga(e.attrs) + ","), e.props && (n += "domProps:" + Ga(e.props) + ","), e.events && (n += Da(e.events, !1) + ","), e.nativeEvents && (n += Da(e.nativeEvents, !0) + ","), e.slotTarget && !e.slotScope && (n += "slot:" + e.slotTarget + ","), e.scopedSlots && (n += function (e, t, n) { var r = e.for || Object.keys(t).some(function (e) { var n = t[e]; return n.slotTargetDynamic || n.if || n.for || Ka(n) }), i = !!e.if; if (!r) for (var o = e.parent; o;){ if (o.slotScope && o.slotScope !== ca || o.for) { r = !0; break } o.if && (i = !0), o = o.parent } var a = Object.keys(t).map(function (e) { return Ja(t[e], n) }).join(","); return "scopedSlots:_u([" + a + "]" + (r ? ",null,true" : "") + (!r && i ? ",null,false," + function (e) { var t = 5381, n = e.length; for (; n;)t = 33 * t ^ e.charCodeAt(--n); return t >>> 0 }(a) : "") + ")" }(e, e.scopedSlots, t) + ","), e.model && (n += "model:{value:" + e.model.value + ",callback:" + e.model.callback + ",expression:" + e.model.expression + "},"), e.inlineTemplate) { var o = function (e, t) { var n = e.children[0]; if (n && 1 === n.type) { var r = Pa(n, t.options); return "inlineTemplate:{render:function(){" + r.render + "},staticRenderFns:[" + r.staticRenderFns.map(function (e) { return "function(){" + e + "}" }).join(",") + "]}" } }(e, t); o && (n += o + ",") } return n = n.replace(/,$/, "") + "}", e.dynamicAttrs && (n = "_b(" + n + ',"' + e.tag + '",' + Ga(e.dynamicAttrs) + ")"), e.wrapData && (n = e.wrapData(n)), e.wrapListeners && (n = e.wrapListeners(n)), n } function Ka(e) { return 1 === e.type && ("slot" === e.tag || e.children.some(Ka)) } function Ja(e, t) { var n = e.attrsMap["slot-scope"]; if (e.if && !e.ifProcessed && !n) return Ua(e, t, Ja, "null"); if (e.for && !e.forProcessed) return za(e, t, Ja); var r = e.slotScope === ca ? "" : String(e.slotScope), i = "function(" + r + "){return " + ("template" === e.tag ? e.if && n ? "(" + e.if + ")?" + (qa(e, t) || "undefined") + ":undefined" : qa(e, t) || "undefined" : Ra(e, t)) + "}", o = r ? "" : ",proxy:true"; return "{key:" + (e.slotTarget || '"default"') + ",fn:" + i + o + "}" } function qa(e, t, n, r, i) { var o = e.children; if (o.length) { var a = o[0]; if (1 === o.length && a.for && "template" !== a.tag && "slot" !== a.tag) { var s = n ? t.maybeComponent(a) ? ",1" : ",0" : ""; return "" + (r || Ra)(a, t) + s } var c = n ? function (e, t) { for (var n = 0, r = 0; r < e.length; r++){ var i = e[r]; if (1 === i.type) { if (Wa(i) || i.ifConditions && i.ifConditions.some(function (e) { return Wa(e.block) })) { n = 2; break } (t(i) || i.ifConditions && i.ifConditions.some(function (e) { return t(e.block) })) && (n = 1) } } return n }(o, t.maybeComponent) : 0, u = i || Za; return "[" + o.map(function (e) { return u(e, t) }).join(",") + "]" + (c ? "," + c : "") } } function Wa(e) { return void 0 !== e.for || "template" === e.tag || "slot" === e.tag } function Za(e, t) { return 1 === e.type ? Ra(e, t) : 3 === e.type && e.isComment ? (r = e, "_e(" + JSON.stringify(r.text) + ")") : "_v(" + (2 === (n = e).type ? n.expression : Xa(JSON.stringify(n.text))) + ")"; var n, r } function Ga(e) { for (var t = "", n = "", r = 0; r < e.length; r++){ var i = e[r], o = Xa(i.value); i.dynamic ? n += i.name + "," + o + "," : t += '"' + i.name + '":' + o + "," } return t = "{" + t.slice(0, -1) + "}", n ? "_d(" + t + ",[" + n.slice(0, -1) + "])" : t } function Xa(e) { return e.replace(/\u2028/g, "\\u2028").replace(/\u2029/g, "\\u2029") } new RegExp("\\b" + "do,if,for,let,new,try,var,case,else,with,await,break,catch,class,const,super,throw,while,yield,delete,export,import,return,switch,default,extends,finally,continue,debugger,function,arguments".split(",").join("\\b|\\b") + "\\b"); function Ya(e, t) { try { return new Function(e) } catch (n) { return t.push({ err: n, code: e }), S } } function Qa(e) { var t = Object.create(null); return function (n, r, i) { (r = A({}, r)).warn; delete r.warn; var o = r.delimiters ? String(r.delimiters) + n : n; if (t[o]) return t[o]; var a = e(n, r), s = {}, c = []; return s.render = Ya(a.render, c), s.staticRenderFns = a.staticRenderFns.map(function (e) { return Ya(e, c) }), t[o] = s } } var es, ts, ns = (es = function (e, t) { var n = la(e.trim(), t); !1 !== t.optimize && ka(n, t); var r = Pa(n, t); return { ast: n, render: r.render, staticRenderFns: r.staticRenderFns } }, function (e) { function t(t, n) { var r = Object.create(e), i = [], o = []; if (n) for (var a in n.modules && (r.modules = (e.modules || []).concat(n.modules)), n.directives && (r.directives = A(Object.create(e.directives || null), n.directives)), n) "modules" !== a && "directives" !== a && (r[a] = n[a]); r.warn = function (e, t, n) { (n ? o : i).push(e) }; var s = es(t.trim(), r); return s.errors = i, s.tips = o, s } return { compile: t, compileToFunctions: Qa(t) } })(Ca), rs = (ns.compile, ns.compileToFunctions); function is(e) { return (ts = ts || document.createElement("div")).innerHTML = e ? '<a href="\n"/>' : '<div a="\n"/>', ts.innerHTML.indexOf("&#10;") > 0 } var os = !!z && is(!1), as = !!z && is(!0), ss = g(function (e) { var t = Yn(e); return t && t.innerHTML }), cs = wn.prototype.$mount; return wn.prototype.$mount = function (e, t) { if ((e = e && Yn(e)) === document.body || e === document.documentElement) return this; var n = this.$options; if (!n.render) { var r = n.template; if (r) if ("string" == typeof r) "#" === r.charAt(0) && (r = ss(r)); else { if (!r.nodeType) return this; r = r.innerHTML } else e && (r = function (e) { if (e.outerHTML) return e.outerHTML; var t = document.createElement("div"); return t.appendChild(e.cloneNode(!0)), t.innerHTML }(e)); if (r) { var i = rs(r, { outputSourceRange: !1, shouldDecodeNewlines: os, shouldDecodeNewlinesForHref: as, delimiters: n.delimiters, comments: n.comments }, this), o = i.render, a = i.staticRenderFns; n.render = o, n.staticRenderFns = a } } return cs.call(this, e, t) }, wn.compile = rs, wn });
window.RES||(window.RES={IMSSL:!1,SSOUrl:[],ERROR:{System:{Title:"系统",RequiredArgs:"缺少必要的参数",NoMatchRecord:"找不到符合条件的记录",NoSuchRecord:"找不到指定的记录",SMSShortInterval:"为免打扰用户，短信发送间隔不能少于60秒，请稍后再试",SMSMaxTimes:"您发送的短信数量已达到上限，请稍后再尝试",InvasiveWarning:"检测到非正常的操作，请停止当前操作并联系客服人员，否则您的行为将被永久记录",SecLimit:"您的帐号安全等级不足以执行所请求的操作",UnknowActionFor:"抱歉，无法确定下一步要执行的操作，请联系客服人员",AccessDenied:"授权失败，访问被拒绝",BadResponse:"返回的数据格式不符合预期",DuplicateObj:"存在重复的记录"},AccountSvc:{Title:"帐号服务",NoAcnt:"登录帐号不能为空",NoMatchAcnt:"此帐号未注册",ErrPassword:"帐号或密码错误",AcntRegisted:"此帐号已被其他用户使用",BadCaptcha:"验证码错误",NoCaptcha:"缺少验证码",NoAcntWithOpensrc:"第三方帐号未在平台注册",OpenAcntBinded:"第三方帐号已绑定给其他用户",MPhoneBinded:"此手机号码已被其他用户绑定",EmailBinded:"此邮箱已被其他用户使用",WeChatBinded:"此微信号已经绑定到其他平台帐号",AcntBindOpenacnt:"您的帐号已绑定了同类型第三方帐号",AcntBindMphoneLimit:"每个帐号最多绑定三个额外的手机号",CreateOpenAcntFail:"绑定第三方帐号失败",ExistCertification:"您的实名认证正在审核中。如果是近期刚刚提交的申请，请耐心等待审核工作完成，此过程大约需要3个工作日",NoMatchCertification:"找不到指定的实名认证申请",UnsuportedOpensrc:"此第三方帐号类型不受支持",FailOnCancelPeople:"未能成功撤销个人实名认证，请联系客服人员"},CompanySvc:{Title:"公司信息管理",CompanyExists:"此公司已注册，或正在审核中",FailOnCreateOrg:"未能成功创建组织架构",FailOnCreatePos:"未能成功创建岗位",FailOnSetPosition:"未能成功设置职员岗位",ExistApplication:"企业管理员正在审核您之前提交的入职申请，请耐心等候",HasBeenEmployee:"您已经是此公司员工，无需重复申请"},AcntController:{Title:"帐号服务",IllegalAcnt:"帐号不能包含非法的特殊符合",ErrCaptcha:"短信验证码不正确"},MyController:{Title:"我的云兮",ErrCaptcha:"短信验证码不正确"},FileController:{Title:"文件服务",UnknowAction:"无法识别请求类型",NoTokenFileStream:"文件校验码或文件名不能同时为空",FailOnSaveFile:"保存文件时发生内部错误",AppendBadStartPosition:"断点续传起始位置与服务器记录不匹配",NoResponseFromWx:"微信服务器未返回指定的文件",NoFileData:"未接收到合法的文件数据，无法启动断点续传"},WeChatController:{Title:"微信服务",GetWxUserFail:"无法获取微信用户信息",NotAuthed:"未得到您的授权",UnknowClient:"无法确定客户端唯一标识",JSAuthFail:"未能获取调用硬件设备的权限",FailOnGetMedia:"未能从微信中获取媒体资源"},OpenTevo:{Title:"开放平台服务",NoMatchApp:"未注册的第三方应用",AccessFail:"身份验证失败",TicketExpired:"访问令牌已失效",TicketError:"访问令牌不合法",UnknowAPI:"无法识别的请求",NoInput:"没有收到预期的数据",BadResponse:"返回数据不符合格式规范",AppTestFail:"应用接口检测失败"},Uploader:{Title:"文件上传",TooLarge:"文件尺寸过大"},MineApp:{NoMatchAcnt:"帐号不存在"},OrganizeSvc:{ReservedPosName:"此岗位名称为系统保留专用，不允许编辑",FailOnCreateOrg:"未能成功创建组织架构",FailOnCreatePos:"未能成功创建岗位"},PurchaseApp:{BadOpenOrderData:"第三方推送的源订单数据不符合格式要求",DuplicateOpenOrder:"重复的源订单",ImportOpenOrderFail:"第三方采购订单导入失败",NoAuthForOrderManage:"请检查您是否有查阅采购订单所需的权限",BadReceiptData:"收货数据不符合格式要求",FailOnAppendOrderAttachment:"由于指定的附件已经存在，未能完成本次操作"},PurchaseController:{GetDlvDataFail:"无法获取送货单数据，请确保您在此订单所属公司有收货操作权限"},SaleApp:{NoAuthForOrderConfirm:"请检查您是否有确认销售订单的相关权限",ErrorTradeStatus:"交易状态不符合操作要求",NoAuthForNewDelivery:"请检查您是否具有登记发货的权限",FailOnNewDelivery:"未能成功执行发货操作，请稍后再试",BadDeliveryData:"提交的发货数据不符合系统要求",CompletedDelivery:"此送货单已完成收货，不允许执行当前操作",FailOnAppendOrderAttachment:"由于指定的附件已经存在，未能完成本次操作",FailOnAcceptInvitee:"未能完成参标报名，请稍后再试",FailOnRejectInvitee:"未能完成操作，请稍后再试",FailOnCreateQuotation:"未能保存报价数据，请稍后再试",BadQuotationData:"提交的报价数据不符合系统要求",FailOnAppendQuotationAttachment:"由于指定的附件已经存在，未能完成本次操作",FailOnCompleteQuotation:"由于意料之外的错误，未能成功完成报价，请稍后再试"},CRMApp:{BadOpenProjectData:"通过开放接口发布的项目数据不符合规范"}},RouteTable:{"/sobiz":{template:"/ui/normal.html"},"/my":{template:"/ui/normal.html",section:{"left-navi":"/my/_navi.html"},map:{"/my/index":{"page-content":"/my/_index.html"}}},"/cloudadmin":{secLv:5,template:"/ui/normal.html",section:{"left-navi":"/cloudadmin/_navi.html"},map:{"/cloudadmin/user":{"page-content":"/cloudadmin/_user.html"},"/cloudadmin/company":{"page-content":"/cloudadmin/_company.html"},"/cloudadmin/ordersync":{"page-content":"/cloudadmin/_ordersync.html"},"/cloudadmin/orderadmin":{"page-content":"/cloudadmin/_orderadmin.html"},"/cloudadmin/timejob":{"page-content":"/cloudadmin/_timejob.html"},"/cloudadmin/wechat":{"page-content":"/cloudadmin/_wechat.html"},"/cloudadmin/spu":{"page-content":"/cloudadmin/Spu/_spu.html"},"/cloudadmin/crmproject":{"page-content":"/cloudadmin/CRM/_projreview.html"}}},"/admin":{template:"/ui/normal.html",section:{"left-navi":"/admin/_navi.html"},map:{"/admin/company":{"page-content":"/admin/_company.html"},"/admin/org":{"page-content":"/admin/_org.html"},"/admin/employee":{"page-content":"/admin/_employee.html"},"/admin/project":{"page-content":"/admin/_project.html"},"/admin/app":{"page-content":"/admin/_app.html"},"/admin/api_syncstockin":{"page-content":"/admin/_api_syncstockin.html"},"/admin/api_rcv_qc":{"page-content":"/admin/_api_rcv_qc.html"},"/admin/api_p_patrol":{"page-content":"/admin/_api_p_patrol.html"}}},"/material/sale":{template:"/ui/normal.html",section:{"left-navi":"/material/sale/_navi.html"},map:{"/material/sale/orders":{"page-content":"/material/sale/_orders.html"},"/material/sale/delivery":{"page-content":"/material/sale/_delivery.html"},"/material/sale/quotation":{"page-content":"/material/sale/_quotation.html"}}},"/material/purchase":{template:"/ui/normal.html",section:{"left-navi":"/material/purchase/_navi.html"},map:{"/material/purchase/inquiries":{"page-content":"/material/purchase/_inquiries.html"},"/material/purchase/orders":{"page-content":"/material/purchase/_orders.html"},"/material/purchase/receipt":{"page-content":"/material/purchase/_receipt.html"},"/material/purchase/patrol":{"page-content":"/material/purchase/_patrol.html"}}},"/crm":{template:"/ui/normal.html",section:{"left-navi":"/crm/_navi.html"},map:{"/crm/projects":{"page-content":"/crm/_projects.html"},"/crm/cstfollow":{"page-content":"/crm/_cstfollow.html"},"/crm/projreview":{"page-content":"/crm/_projreview.html"}}}},SiteConfig:{Material:{title:"供应链",url:"/Material/Home.html",enable:!0},Engine:{title:"工程",url:"/Engine/Home.html",enable:!0},CRM:{title:"客服",url:"/CRM/Home.html",enable:!1}},AuthItems:[{app:"销售",title:"订单管理",memo:"-",auth:"Sale|Order|Manage",taked:!1},{title:"发货管理",memo:"-",auth:"Sale|Delivery|Manage",taked:!1},{title:"报价",memo:"-",auth:"Sale|Quotation|Manage",taked:!1},{app:"采购",title:"订单管理",memo:"-",auth:"Purchase|Order|Manage",taked:!1},{title:"收货管理",memo:"-",auth:"Purchase|Receipt|Manage",taked:!1},{title:"询价",memo:"-",auth:"Purchase|Inquiry|Manage",taked:!1}]});
/// <reference path="jquery.js" />
/// <reference path="res.js" />
'use strict'
//#region Cookie操作方法
jQuery.Cookie = function (name, value, options) {
    /// <summary>
    /// Cookie管理相关方法
    /// </summary>
    /// <param name="name"></param>
    /// <param name="value"></param>
    /// <param name="options">{expires:以分钟为单位的失效时限，默认随会话，path:有效路径，默认根目录，domain:域名，http:仅限http协议读取,secure:安全性}</param>
    /// <returns type=""></returns>
    if (typeof value != 'undefined') {
        // name and value given, set cookie 
        options = options || { path: "/" };
        if (value === null) {
            value = '';
            options.expires = -1;
        }
        else if (typeof value == 'string') {
            //value = JSON.stringify(value);
        }
        else {
            value = JSON.stringify(value);
        }

        var expires = '';
        if (options.expires && (typeof options.expires == 'number' || options.expires.toUTCString())) {
            var date;
            if (typeof options.expires == 'number') {
                date = new Date();
                date.setTime(date.getTime() + options.expires * 60 * 1000);
            } else {
                date = options.expires;
            }
            expires = '; expires=' + date.toUTCString();
        }

        var path = options.path ? '; path=' + options.path : '';
        var domain = options.domain ? '; domain=' + options.domain : '';
        var secure = options.secure ? '; secure' : '';
        var http = options.http ? ';httponly' : '';
        document.cookie = [name, '=', escape(value), expires, path, domain, secure, http].join('');

    } else {
        var cookieValue = null;
        if (document.cookie && document.cookie != '') {
            var cookies = document.cookie.split(';');
            for (var i = 0; i < cookies.length; i++) {
                var cookie = jQuery.trim(cookies[i]);
                if (cookie.substring(0, name.length + 1) == name + '=') {
                    cookieValue = cookie.substring(name.length + 1);
                    break;
                }
            }
        }
        try {
            return JSON.parse(unescape(cookieValue));
        } catch (ex) {
            return unescape(cookieValue);
        }
    }
};
//#endregion

function getUrlParam(name) {
    /// <summary>
    /// 从当前页面路径中获取指定名称的参数项
    /// </summary>
    /// <param name="name"></param>


    var reg = new RegExp("(^|&)" + name + "=([^&]*)(&|$)",'i'); //构造一个含有目标参数的正则表达式对象
    var r = window.location.search.substr(1).match(reg); //匹配目标参数
    if (r != null) {
        return unescape(decodeURI(r[2]));
    } else {
        return null;
    }; //返回参数值
};

function setUrlParam(url, name, value) {
    var newUrl = "";
    var splitIndex = url.indexOf("?") + 1;
    var paramStr = url.substr(splitIndex, url.length);

    newUrl = url.substr(0, splitIndex);

    // - if exist , replace
    var arr = paramStr.split('&');
    for (var i = 0; i < arr.length; i++) {
        var kv = arr[i].split('=');
        if (kv[0] == name) {
            newUrl += kv[0] + "=" + value;
        } else {
            if (kv[1] != undefined) {
                newUrl += kv[0] + "=" + kv[1];
            }
        }
        if (i != arr.length - 1) {
            newUrl += "&";
        }
    }

    // - if new, add
    if (newUrl.indexOf(name) < 0) {
        newUrl += splitIndex == 0 ? "?" + name + "=" + value : "&" + name + "=" + value;
    }
    url = newUrl;
    return newUrl;
};

//#region 通用辅助工具
var ObjHelper = {
    IsEmpty: function IsEmpty(_obj) {
        /// <summary>
        /// 判定一个对象是否为空
        /// </summary>
        /// <param name="_obj">字符串、DOM、数组、JQuery对象</param>
        if (_obj == undefined || _obj == null) {
            return true;
        } else if (typeof _obj == "string") {
            return $.trim(_obj).length == 0;
        } else if (Array.isArray(_obj)) {
            return _obj.length == 0;
        } else if (_obj instanceof jQuery) {
            return _obj.length == 0;
        } else {
            return false;
        }
    },

    IsElement: function IsElement(_obj) {
        /// <summary>
        /// 判断目标对象是否为一个DOM元素或包含DOM元素的JQuery对象
        /// </summary>
        /// <param name="_obj"></param>
        /// <returns type=""></returns>
        if (ObjHelper.IsEmpty(_obj)) {
            return false;
        } else if (_obj.nodeType) {
            return _obj.nodeType === 1 || _obj.nodeType === 11;
        } else if (_obj instanceof jQuery) {
            return _obj.length > 0 && _obj[0].nodeType && _obj[0].nodeType === 1;
        } else {
            return false;
        }
    },

    IsFunc: function IsFunc(_fn) {
        /// <summary>
        /// 判断目标是否为一个函数方法
        /// </summary>
        /// <param name="_fn">目标函数</param>
        /// <returns type=""></returns>
        if (!_fn) {
            return false;
        } else {
            return typeof _fn === "function";
        }
    }
};

//货币符号枚举
var CurrencyEnum = {
    CNY: '￥'
    , USD: '$'
};

//确保浏览器控制台可用
if (!window.console) {
    console = {
        log: function () { },
        error: function () { }
    }
}
else if (!console.error) {
    console.error = function () {

    }
}
else if (!console.log) {
    console.log = function () {

    }
}
else { }

//提供默认简单信息交互方法
window.info = window.info || function (ttl, cnt) { alert("INFO:" + cnt); };
window.error = window.error || function (ttl, err) { alert("ERROR:" + err); };
window.success = window.success || function (ttl, msg) { alert("SUCCESS:" + msg); };
//#endregion

//#region 为原生的DOM元素和JQ对象添加统一的辅助方法
HTMLElement.prototype.vl = function (_newValue) {
    /// <summary>
    /// 获取或设置一个DOM元素的值（根据元素类型text或html）
    /// </summary>
    /// <param name="_newValue" type="type"></param>
    /// <returns type=""></returns>
    if (!ObjHelper.IsEmpty(_newValue)) {
        $(this).vl(_newValue);
        return this;
    } else {
        return $(this).vl();
    }
};

HTMLElement.prototype.ID = function (_newId) {
    /// <summary>
    /// 获取或设置一个DOM元素的ID属性
    /// </summary>
    /// <param name="_newId" type="type"></param>
    /// <returns type=""></returns>
    if (ObjHelper.IsEmpty(_newId)) {
        return $(this).ID();
    } else {
        $(this).ID(_newId);
        return this;
    }
};

HTMLElement.prototype.attr = function (_key, _value) {
    /// <summary>
    /// 获取或设置一个DOM元素的attr属性
    /// </summary>
    /// <param name="_key" type="type"></param>
    /// <param name="_value" type="type"></param>
    /// <returns type=""></returns>
    if (ObjHelper.IsEmpty(_value)) {
        return $(this).attr(_key);
    } else {
        $(this).attr(_key, _value);
        return this;
    }
};

HTMLElement.prototype.disable = function (tip) {
    /// <summary>
    /// 使一个DOM元素处于不可交互状态
    /// </summary>
    /// <param name="_style" type="type"></param>
    /// <returns type=""></returns>
    this.setAttribute("disabled", "disabled");
    var cntEditble = this.getAttribute("contentEditble");
    if (cntEditble === true) {
        this.setAttribute("contentEditble", false);
    };
    this.classList.add("disabled");
    if (tip) {
        this.vl(tip);
    }
    return this;
};

HTMLElement.prototype.enable = function (tip) {
    /// <summary>
    /// 是一个DOM元素处于可交互状态
    /// </summary>
    /// <param name="_style" type="type"></param>
    /// <returns type=""></returns>

    this.removeAttribute("disabled");

    var cntEditble = this.getAttribute("contentEditble");
    if (cntEditble === false) {
        this.setAttribute("contentEditble", true);
    };
    this.classList.remove("disabled");
    if (tip) {
        this.vl(tip);
    }
    return this;
};

HTMLElement.prototype.dispose = function () {
    console.log("html dispose");
    delete this;
};

if (!HTMLElement.prototype.remove) {
    HTMLElement.prototype.remove = function () { console.log("remove", this); };
}

//针对JQuery选择DOM元素后的扩展操作功能
(function ($) {
    $.fn.extend({
        "ID": function ID(_newID) {
            /// <summary>
            /// 为JQuery对象提供与LiberUI控件一致的获取ID属性的方法
            /// </summary>
            /// <param name="_newID"></param>
            if (ObjHelper.IsEmpty(_newID)) {
                var cid = $(this).attr('id');
                if (!cid) {
                    cid = 'id' + Math.random().toString().replace('.', '');
                    $(this).attr('id', cid);
                }
                return cid;
            } else {
                $(this).attr('id', _newID);
                return $(this);
            }
        },

        "dispose": function dispose() {
            /// <summary>
            /// 为JQuery对象提供与LiberUI控件一致的销毁自身的方法
            /// </summary>
            $.each(this, function () {
                $(this).remove('', false);
                delete this;
            });
        },

        "dom": function dom(_elm) {
            if (ObjHelper.IsElement(_elm)) {
                $(this).appendTo(_elm);
                return this;
            } else {
                return $(this);
            }
        },
        "mask": function mask(_cnt, _delay, _fixHeight, _fnOnClick) {
            /// <summary>
            /// 创建一个简单的遮罩层覆盖在指定元素之上
            /// </summary>
            var elm = $(this);
            if (elm.length == 0) {
                return;
            }
            var m = $("<div class='MaskLayer'></div>");

            m[0].addEventListener("click", function (ev) {
                _fnOnClick && _fnOnClick.call(this, ev);
                ev.stopPropagation();
                return false;
            });
            m[0].addEventListener("mousewheel", function (ev) { ev.preventDefault(); ev.stopPropagation(); return false }, { passive: false });
            window.maskIndx = window.maskIndx ? window.maskIndx + 1 : 1;

            if (elm.is("body")) {
                var sty = {
                    "z-index": 10 * window.maskIndx,
                    "height": window.document.documentElement.clientHeight,
                }
                m.css(sty);
                m.prependTo(elm);
            }
            else {
                m.insertAfter(elm);
            }

            m.width(elm.width(true));
            if (_fixHeight) {
                var h = elm.innerHeight();
                if (h == 0) {
                    h = elm[0].scrollHeight;
                }
                m.height(h);
            }
            LayoutHelper.PosToParent(elm, m, "Cover");

            if (ObjHelper.IsElement(_cnt)) {
                _cnt.appendTo(m);
                setTimeout(function (c) {
                    c.find(':enabled').eq(0).focus().select();
                }, 300, _cnt);
                _cnt[0].addEventListener('click', function (ev) {
                    ev.stopPropagation();
                    return false;
                });
                LayoutHelper.Layout2Parent(_cnt, "AllCenter", null, true);
            }
            else {
                m.vl(_cnt);
            }

            var d = parseInt(_delay);
            if (d) {
                var id = m.ID();
                setTimeout(function () { $("#" + id).remove(); }, d * 1000);
            }

            return m;
        },

        "unmask": function unmask(ani) {
            /// <summary>
            /// 移除通过Mask方法创建的遮罩层
            /// </summary>
            /// <param name="noani" type="boolean">是否启用渐隐动画</param>
            /// <returns type=""></returns>
            var mid = $(this).attr("maskid");
            if (mid) {
                if (!ani) {
                    $("#" + mid).remove();
                }
                else {
                    $("#" + mid).fadeOut(1000, function () {
                        this.remove();
                    });
                }
                $(this).removeAttr("maskid");
            }
            else if (!ani) {
                $(this).children(".MaskLayer").remove();
                $(this).siblings(".MaskLayer").remove();
            }
            else {
                $(this).children(".MaskLayer").fadeOut(1000, function () { this.remove(); });
                $(this).siblings(".MaskLayer").fadeOut(1000, function () { this.remove(); });
            }
            window.maskIndx = window.maskIndx ? window.maskIndx - 1 : 1;
            return this;
        },

        "disable": function disable(tip) {
            this.each(function () {
                this.disable();
                if (tip) {
                    this.vl(tip);
                }
            });

            return this;
        },

        "enable": function enable(tip) {
            this.each(function () {
                this.enable(tip);
            });

            return this;
        },

        "vl": function vl(_newValue) {
            var elm = $(this);
            if (_newValue == undefined) {
                if (elm.is("input") || elm.is("textarea")) {
                    return elm.val();
                } else {
                    return elm.html();
                }
            } else {
                if (elm.is("input") || elm.is("textarea")) {
                    elm.val(_newValue);
                } else if (this.nodeType === 3 || this.nodeType === 8 || this.nodeType === 2) {
                    elm.text(_newValue);
                } else {
                    elm.html(_newValue);
                }
                return elm;
            }
        },

        "wait": function wait(_msg, _displayCnt, _loadingImg) {
            /// <summary>
            /// 指定一个元素处于等待状态，并隐藏原有的内容
            /// </summary>
            /// <param name="_msg" type="String Dom">提示文字或元素</param>
            /// <param name="_displayCnt" type="Bool">是否保留原有的内容[默认隐藏]</param>
            /// <param name="_loadingImg" type="Bool">是否使用Gif动画</param>
            /// <returns type=""></returns>
            $(this).each(function () {
                var elm = $(this);
                var wtr = $(this).children(".WaitingWraper");
                if (wtr.length > 0) {
                    wtr.html(_msg);
                }
                else {
                    elm.addClass("Waiting");
                    var h = null;
                    if (!elm[0].style.height) {
                        h = elm.height();
                    };

                    wtr = $("<button class='WaitingWraper'>");
                    if (_loadingImg) {
                        wtr.addClass("withAni");
                    }
                    if (_displayCnt) {
                        wtr.addClass("withCnt");
                    }

                    if (!elm[0].style.height && h) {
                        elm.css("height", h).attr("no-height", "flag");
                    }
                    wtr.prependTo(this).append(_msg).animate({ height: '100%' });

                    wtr.click(function (ev) {
                        ev.preventDefault();
                        ev.stopPropagation();
                        return false;
                    });
                }
            });
            return this;
        },

        "waitEnd": function waitEnd() {
            $(this).each(function () {
                var elm = $(this);

                elm.children(".WaitingWraper").animate({ height: 0, opacity: 0 }, 300, "linear", function (ev) {
                    var nh = elm.attr("no-height");
                    if (nh) {
                        elm.removeClass("Waiting");
                        elm.removeAttr("no-height");
                        elm[0].style.height = null;
                    }
                    this.remove();
                });
            });
            return this;
        },

        "process": function process(ttl, pcr) {
            /// <summary>
            /// 指定一个元素处于执行状态，并隐藏原有的内容
            /// </summary>
            /// <param name="_msg" type="String Dom">提示文字或元素</param>
            /// <param name="_displayCnt" type="Bool">是否保留原有的内容[默认隐藏]</param>
            /// <param name="_loadingImg" type="Bool">是否使用Gif动画</param>
            /// <returns type=""></returns>
            $(this).each(function () {
                var elm = $(this);
                var wtr = $(this).children(".WaitingWraper");
                if (wtr.length == 0) {
                    //初始化进度条内容
                    elm.addClass("Waiting");
                    var h = null;
                    if (!elm[0].style.height) {
                        h = elm.height();
                    }

                    wtr = $("<button class='WaitingWraper withCnt' style='height:100%'><div class='process-bar'></div><span class='process-ttl'>" + ttl.toString() + "</span></button>");

                    if (h) {
                        elm.css("height", h).attr("no-height", "flag");
                    }
                    wtr.prependTo(this);

                    wtr.click(function (ev) {
                        ev.preventDefault();
                        ev.stopPropagation();
                        return false;
                    });
                }

                //更新进度条
                if (!pcr || window.isNaN(pcr) || window.isNaN(parseFloat(pcr))) {
                }
                else {
                    if (pcr > 100) {
                        pcr = "100%";
                    }
                    else if (pcr > 1) {
                        pcr = pcr + "%";
                    }
                    else {
                        pcr = pcr.formatPercent(0);
                    }
                    wtr.children(".process-bar").css("width", pcr);
                }
                wtr.children(".process-ttl").text(ttl);

            });
            return this;
        },

        "processEnd": function processEnd() {
            $(this).each(function () {
                var elm = $(this);

                elm.children(".WaitingWraper").animate({ height: 0, opacity: 0 }, 300, "linear", function (ev) {
                    var nh = elm.attr("no-height");
                    if (nh) {
                        elm.removeClass("Waiting");
                        elm.removeAttr("no-height");
                        elm[0].style.height = null;
                    }
                    this.remove();
                });
            });
            return this;
        },

        "CheckAll": function (ruls) {
            if (this.data("checker")) {
                return this.data("checker").CheckAll(ruls);
            } else { return true; };
        }
    });
})(jQuery);

//#endregion

//#region 布局帮助类方法
var LayoutHelper = {
    Layout2Parent: function Layout2Parent(_targetDOM, _mode, _offset, _absolute) {
        /// <summary>
        /// 将目标元素按指定方式定位到相对其父元素的位置
        /// </summary>
        /// <param name="_targetDOM"></param>
        /// <param name="_mode">定位模式[YCenter,XCenter,AllCenter,Cover]</param>
        /// <param name="_offset">偏移[top,bottom,left,right]</param>
        /// <param name="_absolute">是否使用绝对定位(正常情况下没有区别)</param>
        var tgt = $(_targetDOM);
        var isAbsolute = false;
        if (_absolute === true) {
            isAbsolute = true;
            tgt.css("position", "absolute");
        }
        var p = tgt.parent().eq(0);
        var off = $.extend({ top: 0, bottom: 0, left: 0, right: 0 }, _offset);
        var h = tgt.outerHeight(true);
        if (h == 0) {
            h = tgt[0].scrollHeight;
        }
        var w = tgt.outerWidth(true);
        var ph = p.height();
        var pw = p.width();

        switch (_mode) {
            case "YCenter":
                tgt.css("top", (ph - h) / 2 + off.top - off.bottom + "px");
                break;
            case "XCenter":
                //tgt.css("left", ((pw - w)/2 + off.left - off.right)+"px");
                break;
            case "AllCenter":
                if (tgt.css("position") !== 'absolute' && tgt.css("position") !== 'fixed') {
                    //非绝对定位
                    var style = {
                        position: 'relative',
                        top: (ph - h) / 2 + off.top - off.bottom + 'px',
                        margin: '0 auto'
                    }
                    tgt.css(style);
                }
                else {
                    var style = {
                        left: ((pw - w) / 2 + off.left - off.right) / pw * 100 + '%',
                        top: Math.abs(((ph - h) / 2 + off.top - off.top)) / ph * 100 + '%'
                    }
                    tgt.css(style);
                }
                break;
            case "Bottom":
                tgt.css("top", 0 - ph).css("left", w - pw);
                break;
            default:
                tgt.offset(off);
                break;
        }
        p = null;
        off = null;
    },

    Layout2Wnd: function Layout2Wnd(_targetDOM, _mode, _offset) {
        /// <summary>
        /// 将目标元素按指定方式定位到当前窗口的相对位置
        /// </summary>
        /// <param name="_targetDOM"></param>
        /// <param name="_mode">定位模式[YCenter,XCenter,AllCenter,Cover]</param>
        /// <param name="_offset">偏移[top,bottom,left,right]</param>
        /// <param name="_absolute">是否使用绝对定位(正常情况下没有区别)</param>
        var tgt = $(_targetDOM);
        tgt.css("position", "fixed");

        var p = $("html");
        var off = $.extend({ top: 0, bottom: 0, left: 0, right: 0 }, _offset);
        var h = tgt.outerHeight(true);
        if (h == 0) {
            h = tgt[0].scrollHeight;
        }
        var w = tgt.outerWidth(true);

        var th = document.body.clientHeight;
        var tw = document.body.clientWidth;

        switch (_mode) {
            case "YCenter":
                tgt.css("top", (th - h) / 2 + off.top - off.bottom + 'px');
                break;
            case "XCenter":
                tgt.css("left", (tw - w + p[0].scrollLeft) / 2 + off.left - off.right + 'px');
                break;
            case "AllCenter":
                tgt.css("top", (th - h) / 2 + off.top - off.bottom + 'px');
                tgt.css("left", (tw - w + p[0].scrollLeft) / 2 + off.left - off.right + 'px');
                break;
            case "Cover":
                tgt.css('height', th + 'px').css('width', tw + 'px');
                break;
            case "Bottom":
                tgt.css("top", 0 - th).css("left", w - tw);
                break;
            default:
                tgt.offset(off);
                break;
        }
        p = null;
        off = null;
    },

    PosToBody: function PosToBody(_refElm, _elm, _pos, _offset, final) {
        /// <summary>
        /// 将Body中的某个子元素定位到指定元素附近(注意：窗口尺寸改变时需重新定位)
        /// </summary>
        /// <param name="_refElm">定位的参照目标元素</param>
        /// <param name="_elm">要改变位置的元素（必须是body的直接子元素,且是绝对定位）</param>
        /// <param name="方位">方向定义（cover,right,right-down,down,down-left,down-right,left-down,left,left-up,up,mid）</param>
        /// <param name="_offset">定位坐标偏移(可以是绝对数值，或相对参照目标的百分比)</param>

        var refpos = _refElm.offset(); //获取参照目标相对body的偏移坐标
        var refParent = _refElm.offsetParent();
        if (refParent.css('position') == 'relative') {
            refParent = refParent.offsetParent();
        }

        var rp_top = parseInt(refParent.css("paddingTop"));
        var rp_left = parseInt(refParent.css("paddingLeft"));

        var eh = _elm.outerHeight();
        var ew = _elm.outerWidth();
        var rw = _refElm.outerWidth();
        var rh = _refElm.outerHeight();

        if (!_offset) {
            _offset = { top: 0, left: 0 };
        } else {
            if (!_offset['top']) {
                _offset.top = 0;
            } else if (_offset.top.toString().slice(-1) === '%') {
                _offset.top = rh * parseFloat(_offset.top) / 100;
            }

            if (!_offset['left']) {
                _offset.left = 0;
            } else if (_offset.left.toString().slice(-1) === '%') {
                _offset.left = rw * parseFloat(_offset.left) / 100;
            }
        }
        var dst = {
            left: parseFloat(_elm.css("left")) || 0,
            top: parseFloat(_elm.css("top")) || 0
        };  //获取当前元素相对坐标

        var epos = _elm.offset();
        switch (_pos) {
            case "right-up":
                dst.top = refpos.top - eh - _offset.top;
                dst.left = refpos.left + rw + _offset.left;
                break;
            case "down-left":
                dst.top = refpos.top + rh - rp_top + _offset.top;
                dst.left = refpos.left + _offset.left;
                break;
            case "cover":
                dst.top = refpos.top - rp_top;
                dst.left = refpos.left - rp_left;
                break;
            case "down-right":
                dst.top = refpos.top + rh + _offset.top;
                dst.left = refpos.left + rw - ew + _offset.left;
                break;
            case "left-up":
                dst.top = refpos.top - eh + _offset.top;
                dst.left = refpos.left + _offset.left;
                break;
            default:
                break;
        }
        _elm[0].style.z = _refElm[0].style.z + 1;
        switch (_elm.css('position')) {
            case "absolute":
                _elm.css('top', dst.top).css('left', dst.left);
                break;
            default:
                _elm.css('top', dst.top).css('left', dst.left);
                break;
        }
        if (!final) {
            setTimeout(PosToBody, 100, _refElm, _elm, _pos, _offset, true);
        }

    },

    PosToParent: function PosToParent(_refElm, _elm, _pos) {
        /// <summary>
        /// 将同一个父元素中的某个元素以绝对定位方式定位在指定元素的相对位置上
        /// </summary>
        /// <param name="_refElm" type="type"></param>
        /// <param name="_elm" type="type"></param>
        /// <param name="_pos" type="type"></param>
        var rof = _refElm.offset();
        var tof = _elm.offset();
        var pof = _refElm.offsetParent().offset();
        switch (_pos) {
            case "Cover":
                if (_refElm.is("body")) {
                    var dst = {
                        "position": 'fixed',
                        "top": 0,
                        "z-index": _elm.css("zIndex") || 100,
                        "height": window.document.documentElement.clientHeight
                    }
                    _elm.css(dst);
                }
                else {
                    var pmode = _refElm.offsetParent().css("position");
                    var rmode = _refElm.css("position");

                    var dst = {
                        top: rof.top,
                        left: rof.left
                    };
                    if (pmode == "relative" || pmode == "static") {
                        if (rmode == "absolute") {
                            dst = {
                                top: rof.top - tof.top,
                                left: rof.left - tof.left
                            }
                        }
                        else {
                            dst = {
                                top: rof.top - tof.top,
                                left: rof.left - tof.left
                            }
                        }
                    }
                    else if (pmode == "absolute") {
                        if (rmode == "absolute") {
                            var p = _refElm.offsetParent();
                            dst = {
                                top: rof.top / p.height() * 100 + "%",
                                left: rof.left / p.width() * 100 + "%"
                            }
                        }
                        else {
                            dst = {
                                top: rof.top - tof.top,
                                left: rof.left - pof.left
                            }
                        }

                    }
                    else if (pmode == "fixed") {
                        dst = {
                            top: rof.top,
                            left: rof.left - pof.left
                        }
                    }
                    else {
                        dst = {
                            top: rof.top - tof.top,
                            left: rof.left - pof.left
                        }
                    }

                    _elm.css(dst);
                }

                break;
        }
    }
};
//#endregion

//#region 键盘帮助类
function KeypressMonitor() {
    var instance = this;
    instance.Global = {};
    var tgts = {};
    function onPress(ev) {
        var char = '';
        switch (ev.keyCode) {
            case 13:
                if (ev.ctrlKey) {
                    char = 'ctrl+enter';
                } else {
                    char = 'enter';
                }
                break;
            case 16:
                char = 'shift';
                break;
            case 17:
                char = 'ctrl';
                break;
            case 18:
                char = 'alt';
                break;
            case 20:
                char = 'capslock';
                break;
            case 32:
                char = 'space';
                break;
            case 186:
                if (ev.shiftKey) {
                    char = ':';
                } else {
                    char = ';';
                }
                break;
            case 188:
                if (ev.shiftKey) {
                    char = '<';
                } else {
                    char = ',';
                }
                break;
            case 190:
                if (ev.shiftKey) {
                    char = '>';
                } else {
                    char = '.';
                }
                break;
            default:
                char = String.fromCharCode(ev.keyCode);
                break;
        }
        ev = jQuery.Event(ev);
        var $elm = $(ev.originalEvent.srcElement);
        ev.Dom = $elm;
        var id = $elm.attr('id');

        //先看看有没有全局事件绑定
        if (instance.Global[char] && instance.Global[char].length > 0) {
            for (var i = instance.Global[char].length - 1; i > -1; i--) {
                instance.Global[char][i].call(this, ev, char);
                if (ev.isPropagationStopped()) {
                    break;
                }
            }
        } else if (instance.Global['*'] && instance.Global['*'].length > 0) {
            for (var i = instance.Global[char].length - 1; i > -1; i--) {
                instance.Global['*'][i].call(this, ev, char);
                if (ev.isPropagationStopped()) {
                    break;
                }
            }
            //instance.Global['*'][0].call(this, ev, char);
        } else { }

        //再看看有没有绑定特定元素
        if (tgts[id]) {
            if (char != '' && !tgts[id].handed) {
                tgts[id].handed = true;
                notifyKeyEvent(char, id, ev);
            } else {
                tgts[id].handed = false;
            }
        }
    };

    function onDown(ev) {
        var char = '';
        switch (ev.keyCode) {
            case 8:
                char = 'backspace';
                break;
            case 9:
                char = 'tab';
                break;
            case 40:
                char = 'down';
                break;
            case 38:
                char = 'up';
                break;
            case 27:
                char = 'esc';
                break;
        }
        if (ObjHelper.IsEmpty(char)) {
            return;
        }
        ev = jQuery.Event(ev);
        var $elm = $(ev.originalEvent.srcElement);
        ev.Dom = $elm;
        var id = $elm.attr('id');
        //先看看有没有全局事件绑定
        if (instance.Global[char] && instance.Global[char].length > 0) {
            for (var i = instance.Global[char].length - 1; i > -1; i--) {
                instance.Global[char][i].call(this, ev, char);
                if (ev.isPropagationStopped()) {
                    break;
                }
            }
        } else if (instance.Global['*'] && instance.Global['*'].length > 0) {
            for (var i = instance.Global[char].length - 1; i > -1; i--) {
                instance.Global['*'][i].call(this, ev, char);
                if (ev.isPropagationStopped()) {
                    break;
                }
            }
            //instance.Global['*'][0].call(this, ev, char);
        } else { }

        //再看看有没有绑定特定元素
        if (tgts[id]) {
            if (char != '' && !tgts[id].handed) {
                tgts[id].handed = true;
                notifyKeyEvent(char, id, ev);
            } else {
                tgts[id].handed = false;
            }
        }
    };

    function onInput(ev) {
        ev = jQuery.Event(ev);
        var $elm = $(ev.originalEvent.srcElement);
        ev.Dom = $elm;
        var id = $elm.attr('id');
        var char = '';
        var v = $elm.vl();
        char = v.slice(v.length - 1, v.length);
        switch (char) {
            case "。":
                char = '.';
                break;
            case "，":
                char = ',';
                break;
            case "：":
                char = ":";
                break;
        }
        //先看看有没有全局事件绑定
        if (instance.Global[char] && instance.Global[char].length > 0) {
            for (var i = instance.Global[char].length - 1; i > -1; i--) {
                instance.Global[char][i].call(this, ev, char);
                if (ev.isPropagationStopped()) {
                    break;
                }
            }
        } else if (instance.Global['*'] && instance.Global['*'].length > 0) {
            for (var i = instance.Global[char].length - 1; i > -1; i--) {
                instance.Global['*'][i].call(this, ev, char);
                if (ev.isPropagationStopped()) {
                    break;
                }
            }
        } else { }

        //再看看有没有绑定特定元素
        if (tgts[id]) {
            if (char != '' && !tgts[id].handed) {
                tgts[id].handed = true;
                notifyKeyEvent(char, id, ev);
            } else {
                tgts[id].handed = false;
            }
        }
    };

    function notifyKeyEvent(char, id, ev) {
        ev.Char = char;
        //首先看是否针对特定字符绑定了处理函数
        var hs = tgts[id][char];
        if (hs) {
            for (var i = hs.length - 1; i > -1; i--) {
                if (ObjHelper.IsFunc(hs[i])) {
                    hs[i](ev, char);
                    if (ev.isPropagationStopped()) {
                        break;
                    }
                }
            }
        } else {
            //如果没有，看是否针对任意按键都绑定了处理事件
            hs = tgts[id]['*'];
            if (hs) {
                for (var i = hs.length - 1; i > -1; i--) {
                    if (ObjHelper.IsFunc(hs[i])) {
                        hs[i](ev, char);
                        if (ev.isPropagationStopped()) {
                            break;
                        }
                    }
                }
            }
        }
    };

    window.onkeydown = onDown;
    window.onkeypress = onPress;
    window.oninput = onInput;

    this.on = function (_elm, _char, _fn) {
        /// <summary>
        /// 将指定方法绑定到目标Dom元素的特殊键盘事件
        /// </summary>
        /// <param name="_elm">要监视其键盘事件的元素</param>
        /// <param name="_char">要监视的特定输入值【enter,esc,space,dot,slash,backslash,backspace,colon】</param>
        /// <param name="_fn">要回调的方法</param>
        var id = _elm.ID();
        var char = _char.toString().trim();
        if (!id) {
            id = 'id' + Math.random();
            _elm.ID(id);
        }

        if (!tgts[id]) {
            tgts[id] = {};
            tgts[id][char] = [];
        } else if (!tgts[id][char]) {
            tgts[id][char] = [];
        }
        tgts[id][char].push(_fn);
        return instance;
    };

    this.off = function (_elm, _char, _fn) {
        /// <summary>
        /// 解除特定的或所有的事件绑定
        /// </summary>
        /// <param name="_elm"></param>
        /// <param name="_char"></param>
        /// <param name="_fn">指定要解除的方法，如果为空，则解除所有的事件绑定</param>
        var id = _elm.ID();
        if (ObjHelper.IsEmpty(_char)) {
            if (tgts.hasOwnProperty(id)) {
                ObjHelper.DisposeObj(tgts[id]);
                tgts[id] = null;
            }
        } else {
            //TODO：解除对特定键盘输入值的监控
        }
        return instance;
    };

    this.globalOn = function (_char, _fn) {
        /// <summary>
        /// 绑定全局特定按键（只有最后注册的方法会得到键盘消息，除非此方法被globalOff调用移除）
        /// </summary>
        /// <param name="_char"></param>
        /// <param name="_fn"></param>
        /// <returns type=""></returns>
        if (!ObjHelper.IsFunc(_fn)) {
            return this;
        }
        if (instance.Global.hasOwnProperty(_char)) {
            var chs = instance.Global[_char];
            //for (var i = 0; i < chs.length; i++) {
            //    if (chs[i] === _fn) {
            //        chs.swap(0, i);
            //        return this;
            //    }
            //}
            chs.push(_fn);
            return this;
        } else {
            instance.Global[_char] = [];
            instance.Global[_char].push(_fn);
            return this;
        }
    };

    this.globalOff = function (_char, _fn) {
        /// <summary>
        /// 解除绑定的全局按键事件
        /// </summary>
        /// <param name="_char"></param>
        /// <param name="_fn"></param>
        /// <returns type=""></returns>
        if (!ObjHelper.IsFunc(_fn)) {
            return this;
        }
        if (instance.Global.hasOwnProperty(_char)) {
            var hs = instance.Global[_char];
            for (var i = 0; i < hs.length; i++) {
                if (hs[i] == _fn) {
                    hs.splice(i, 1);
                }
            }
            return this;
        }
        return this;
    };

    this.Dispose = function () {
        $(window).off('keypress', onPress).off('keydown', onDown);
        window.oninput = null;
        ObjHelper.DisposeObj(instance);
        instance = null;
    };

    return instance;
}
if (!window.KeybordHelper) {
    var KeybordHelper = new KeypressMonitor();
};

//#endregion

Math.diff = function (num1, num2) {
    /// <summary>
    /// 精确比较两个浮点数的差异值
    /// </summary>
    /// <param name="num1" type="Number">数值1</param>
    /// <param name="num2" type="Number">数值2</param>
    /// <returns type="Number">差异值</returns>
    var pow = 10000;
    return (num1 * pow - num2 * pow) / 10000;
}

//#region Array对象操作方法扩展
Array.prototype.eq = function (_index) {
    return this[_index];
};
Array.prototype.findValue = function (v) {
    if (this.length == 0 || !v) { return null; };
    var vv = v.toString();
    for (var i = 0; i < this.length; i++) {
        if (this[i].toString() === vv) {
            return this[i];
        }
    }
    return null;
};
Array.prototype.findObj = function (_field, _value, _newobj, deepsearch) {
    /// <summary>
    /// 在数组中查找具有指定属性或指定属性的值符合条件的第一个对象
    /// </summary>
    /// <param name="_field" type="type">属性名</param>
    /// <param name="_value" type="type">筛选值，不指定则返回第一个指定名称属性值不为null的</param>
    /// <param name="_newobj" type="type"></param>
    /// <param name="deepsearch" type="boolean">执行树结构的深度搜索</param>
    /// <returns type=""></returns>
    if (this.length == 0) {
        return null;
    };
    if (_value !== null && _value !== undefined) {
        for (var i = 0; i < this.length; i++) {
            if (this[i].hasOwnProperty(_field) && this[i][_field] == _value) {
                if (!ObjHelper.IsEmpty(_newobj)) {
                    this[i] = _newobj;
                }
                return this[i];
            }
            else if (deepsearch && this[i].children && this[i].children instanceof Array) {
                var d = this[i].children.findObj(_field, _value, _newobj, deepsearch);
                if (d !== null) {
                    return d;
                }
            }
            else {

            }
        }
    }
    else {
        for (var i = 0; i < this.length; i++) {
            if (this[i].hasOwnProperty(_field)) {
                if (!ObjHelper.IsEmpty(_newobj)) {
                    this[i] = _newobj;
                }
                return this[i];
            }
            else if (deepsearch && this[i].children && this[i].children instanceof Array) {
                var d = this[i].children.findObj(_field, _value, _newobj, deepsearch);
                if (d) {
                    return d;
                }
            }
            else {

            }
        };
    };
    return null;
};
Array.prototype.findObjIndex = function (_field, _value, _newobj) {
    if (this.length == 0) {
        return -1;
    };
    for (var i = 0; i < this.length; i++) {
        if (this[i].hasOwnProperty(_field) && this[i][_field] == _value) {
            if (!ObjHelper.IsEmpty(_newobj)) {
                this[i] = _newobj;
            }
            return i;
        }
        else {

        }
    };
    return -1;
};
Array.prototype.filterBy = function (_field, _value) {
    if (ObjHelper.IsFunc(_field)) {
        return this.filter(_field);
    };
    var rsult = [];
    if (this.length == 0) {
        return rsult;
    };
    if (!ObjHelper.IsEmpty(_value)) {
        for (var i = 0; i < this.length; i++) {
            if (this[i].hasOwnProperty(_field) && this[i][_field] == _value) {
                rsult.push(this[i]);
            }
        };
    } else {
        for (var i = 0; i < this.length; i++) {
            if (this[i].hasOwnProperty(_field) && this[i][_field] !== null && this[i][_field] !== undefined && this[i][_field] !== NaN) {
                rsult.push(this[i]);
            }
        };
    };
    return rsult;
};
Array.prototype.joinAttr = function (_field) {
    if (this.length == 0) {
        return [];
    } else {
        var rtn = [];
        for (var i = 0; i < this.length; i++) {
            if (this[i][_field]) {
                rtn.push(this[i][_field]);
            }
        };
        return rtn;
    };
};
Array.prototype.merge = function (_array, _pk, _fk) {
    var tmp = [];
    for (var i = 0; i < _array.length; i++) {
        var p = this.findObj(_pk, _array[i][_fk]);
        if (!p) {
            tmp.push(_array[i]);
        }
    };
    return this.push.apply(this, tmp);
};
Array.prototype.removeBy = function (_field, _value) {
    for (var i = 0; i < this.length; i++) {
        if (this[i][_field] && this[i][_field] === _value) {
            this.splice(i, 1);
        }
    };
    return this;
};
Array.prototype.removeOn = function (_value) {
    for (var i = 0; i < this.length; i++) {
        if (this[i] && this[i] === _value) {
            this.splice(i, 1);
        }
    };
    return this;
};
Array.prototype.asTree = function (k, pk) {
    /// <summary>
    /// 根据指定主键和父级键将当前平行数组转换为一个标准树型结构
    /// </summary>
    /// <param name="k" type="type"></param>
    /// <param name="pk" type="type"></param>
    if (this.length < 2) {
        return this;
    };
    var rtn = [];

    for (var i = 0; i < this.length; i++) {
        var pid = this[i][pk];
        var pobj = this.findObj(k, pid);
        if (pobj !== null) {
            if (!pobj.children) {
                if (Vue) {
                    Vue.set(pobj, "children", []);
                }
                else {
                    pobj.children = [];
                }

            }
            pobj.children.push(this[i]);
            pobj._ex = true;
        }
        else {
            rtn.push(this[i]);
        }

        this[i]._sub_expanded = true;
    };

    return rtn;
};
Array.prototype.appendTreeNode = function (k, pid, obj) {
    /// <summary>
    /// 根据指定主键和父级键向当前标准树型结构中添加节点
    /// </summary>
    /// <param name="k" type="type"></param>
    /// <param name="pk" type="type"></param>
    /// <param name="obj" type="type"></param>
    var pobj = this.findObj(k, pid, null, true);
    if (pobj != null) {
        if (!pobj.children) {
            if (Vue) {
                Vue.set(pobj, "children", []);
            }
            else {
                pobj.children = [];
            }
        }
        pobj.children.push(obj);
        pobj._ex = true;
    }
    obj._sub_expanded = true;
    return this;
};
Array.prototype.distinc = function (_field) {
    /// <summary>
    /// 根据指定键对数组对象去重并返回一个新数组
    /// </summary>
    var tmp = {};
    var tmpArray = [];
    this.forEach(function (a) {
        if (a.hasOwnProperty(_field) && !tmp.hasOwnProperty(a[_field])) {
            tmp[a._field] = 1;
            tmpArray.push(a);
        }
    });
    tmp = null;
    return tmpArray;
}
//#endregion

//#region String扩展方法
String.prototype.toJSON = function () {
    /// <summary>
    /// 将JSON格式的字符串转为标准的JSON对象
    /// </summary>
    /// <returns type=""></returns>
    if (this.length > 2) {
        return JSON.parse(this.replace(/&quot;/g, '\"').replace(/&gt;/g, '>').replace(/&lt;/g, '<'));
    } else {
        return null;
    }
};

String.prototype.noHtml = function () {
    /// <summary>
    /// 去除字符串中的Html标记
    /// </summary>
    /// <returns type=""></returns>
    return this.replace(/<\/?[^>]*>/g, '').replace(/[ | ]*\n/g, '\n').replace(/&nbsp;/ig, '').trim();
};

String.prototype.MD5 = function () {
    return $.md5(this);
};

var I64BIT_TABLE = ["A", "B", "C", "D", "E", "F", "G", "H", "I", "J", "K", "L", "M", "N", "O", "P", "Q", "R", "S", "T", "U", "V", "W", "X", "Y", "Z", "a", "b", "c", "d", "e", "f", "g", "h", "i", "j", "k", "l", "m", "n", "o", "p", "q", "r", "s", "t", "u", "v", "w", "x", "y", "z", "0", "1", "2", "3", "4", "5", "6", "7", "8", "9", "_", "-", "/", "?", "&"];

String.prototype.hashCode = function () {
    var hash = 5381;
    var i = this.length - 1;
    for (; i > -1; i--)
        hash += (hash << 5) + this.charCodeAt(i);
    var value = hash & 0x7FFFFFFF;

    var retValue = '';
    do {
        retValue += I64BIT_TABLE[value & 0x3F];
    }
    while (value >>= 6);

    return retValue;
};

String.prototype.md4 = function () {
    var v = "";
    var p = this.length;

    for (var i = 0; i < this.length; i++) {
        v += "-" + (this.charCodeAt(i) - p).toString(16);
    };
    return p.toString() + v;
};

(function ($) {
    var rotateLeft = function rotateLeft(lValue, iShiftBits) {
        return lValue << iShiftBits | lValue >>> 32 - iShiftBits;
    };

    var addUnsigned = function addUnsigned(lX, lY) {
        var lX4, lY4, lX8, lY8, lResult;
        lX8 = lX & 0x80000000;
        lY8 = lY & 0x80000000;
        lX4 = lX & 0x40000000;
        lY4 = lY & 0x40000000;
        lResult = (lX & 0x3FFFFFFF) + (lY & 0x3FFFFFFF);
        if (lX4 & lY4) return lResult ^ 0x80000000 ^ lX8 ^ lY8;
        if (lX4 | lY4) {
            if (lResult & 0x40000000) return lResult ^ 0xC0000000 ^ lX8 ^ lY8; else return lResult ^ 0x40000000 ^ lX8 ^ lY8;
        } else {
            return lResult ^ lX8 ^ lY8;
        }
    };

    var F = function F(x, y, z) {
        return x & y | ~x & z;
    };

    var G = function G(x, y, z) {
        return x & z | y & ~z;
    };

    var H = function H(x, y, z) {
        return x ^ y ^ z;
    };

    var I = function I(x, y, z) {
        return y ^ (x | ~z);
    };

    var FF = function FF(a, b, c, d, x, s, ac) {
        a = addUnsigned(a, addUnsigned(addUnsigned(F(b, c, d), x), ac));
        return addUnsigned(rotateLeft(a, s), b);
    };

    var GG = function GG(a, b, c, d, x, s, ac) {
        a = addUnsigned(a, addUnsigned(addUnsigned(G(b, c, d), x), ac));
        return addUnsigned(rotateLeft(a, s), b);
    };

    var HH = function HH(a, b, c, d, x, s, ac) {
        a = addUnsigned(a, addUnsigned(addUnsigned(H(b, c, d), x), ac));
        return addUnsigned(rotateLeft(a, s), b);
    };

    var II = function II(a, b, c, d, x, s, ac) {
        a = addUnsigned(a, addUnsigned(addUnsigned(I(b, c, d), x), ac));
        return addUnsigned(rotateLeft(a, s), b);
    };

    var convertToWordArray = function convertToWordArray(string) {
        var lWordCount;
        var lMessageLength = string.length;
        var lNumberOfWordsTempOne = lMessageLength + 8;
        var lNumberOfWordsTempTwo = (lNumberOfWordsTempOne - lNumberOfWordsTempOne % 64) / 64;
        var lNumberOfWords = (lNumberOfWordsTempTwo + 1) * 16;
        var lWordArray = Array(lNumberOfWords - 1);
        var lBytePosition = 0;
        var lByteCount = 0;
        while (lByteCount < lMessageLength) {
            lWordCount = (lByteCount - lByteCount % 4) / 4;
            lBytePosition = lByteCount % 4 * 8;
            lWordArray[lWordCount] = lWordArray[lWordCount] | string.charCodeAt(lByteCount) << lBytePosition;
            lByteCount++;
        }
        lWordCount = (lByteCount - lByteCount % 4) / 4;
        lBytePosition = lByteCount % 4 * 8;
        lWordArray[lWordCount] = lWordArray[lWordCount] | 0x80 << lBytePosition;
        lWordArray[lNumberOfWords - 2] = lMessageLength << 3;
        lWordArray[lNumberOfWords - 1] = lMessageLength >>> 29;
        return lWordArray;
    };

    var wordToHex = function wordToHex(lValue) {
        var WordToHexValue = "",
            WordToHexValueTemp = "",
            lByte,
            lCount;
        for (lCount = 0; lCount <= 3; lCount++) {
            lByte = lValue >>> lCount * 8 & 255;
            WordToHexValueTemp = "0" + lByte.toString(16);
            WordToHexValue = WordToHexValue + WordToHexValueTemp.substr(WordToHexValueTemp.length - 2, 2);
        }
        return WordToHexValue;
    };

    var uTF8Encode = function uTF8Encode(string) {
        string = string.replace(/\x0d\x0a/g, "\x0a");
        var output = "";
        for (var n = 0; n < string.length; n++) {
            var c = string.charCodeAt(n);
            if (c < 128) {
                output += String.fromCharCode(c);
            } else if (c > 127 && c < 2048) {
                output += String.fromCharCode(c >> 6 | 192);
                output += String.fromCharCode(c & 63 | 128);
            } else {
                output += String.fromCharCode(c >> 12 | 224);
                output += String.fromCharCode(c >> 6 & 63 | 128);
                output += String.fromCharCode(c & 63 | 128);
            }
        }
        return output;
    };

    $.extend({
        md5: function md5(string) {
            var x = Array();
            var k, AA, BB, CC, DD, a, b, c, d;
            var S11 = 7,
                S12 = 12,
                S13 = 17,
                S14 = 22;
            var S21 = 5,
                S22 = 9,
                S23 = 14,
                S24 = 20;
            var S31 = 4,
                S32 = 11,
                S33 = 16,
                S34 = 23;
            var S41 = 6,
                S42 = 10,
                S43 = 15,
                S44 = 21;
            string = uTF8Encode(string);
            x = convertToWordArray(string);
            a = 0x67452301; b = 0xEFCDAB89; c = 0x98BADCFE; d = 0x10325476;
            for (k = 0; k < x.length; k += 16) {
                AA = a; BB = b; CC = c; DD = d;
                a = FF(a, b, c, d, x[k + 0], S11, 0xD76AA478);
                d = FF(d, a, b, c, x[k + 1], S12, 0xE8C7B756);
                c = FF(c, d, a, b, x[k + 2], S13, 0x242070DB);
                b = FF(b, c, d, a, x[k + 3], S14, 0xC1BDCEEE);
                a = FF(a, b, c, d, x[k + 4], S11, 0xF57C0FAF);
                d = FF(d, a, b, c, x[k + 5], S12, 0x4787C62A);
                c = FF(c, d, a, b, x[k + 6], S13, 0xA8304613);
                b = FF(b, c, d, a, x[k + 7], S14, 0xFD469501);
                a = FF(a, b, c, d, x[k + 8], S11, 0x698098D8);
                d = FF(d, a, b, c, x[k + 9], S12, 0x8B44F7AF);
                c = FF(c, d, a, b, x[k + 10], S13, 0xFFFF5BB1);
                b = FF(b, c, d, a, x[k + 11], S14, 0x895CD7BE);
                a = FF(a, b, c, d, x[k + 12], S11, 0x6B901122);
                d = FF(d, a, b, c, x[k + 13], S12, 0xFD987193);
                c = FF(c, d, a, b, x[k + 14], S13, 0xA679438E);
                b = FF(b, c, d, a, x[k + 15], S14, 0x49B40821);
                a = GG(a, b, c, d, x[k + 1], S21, 0xF61E2562);
                d = GG(d, a, b, c, x[k + 6], S22, 0xC040B340);
                c = GG(c, d, a, b, x[k + 11], S23, 0x265E5A51);
                b = GG(b, c, d, a, x[k + 0], S24, 0xE9B6C7AA);
                a = GG(a, b, c, d, x[k + 5], S21, 0xD62F105D);
                d = GG(d, a, b, c, x[k + 10], S22, 0x2441453);
                c = GG(c, d, a, b, x[k + 15], S23, 0xD8A1E681);
                b = GG(b, c, d, a, x[k + 4], S24, 0xE7D3FBC8);
                a = GG(a, b, c, d, x[k + 9], S21, 0x21E1CDE6);
                d = GG(d, a, b, c, x[k + 14], S22, 0xC33707D6);
                c = GG(c, d, a, b, x[k + 3], S23, 0xF4D50D87);
                b = GG(b, c, d, a, x[k + 8], S24, 0x455A14ED);
                a = GG(a, b, c, d, x[k + 13], S21, 0xA9E3E905);
                d = GG(d, a, b, c, x[k + 2], S22, 0xFCEFA3F8);
                c = GG(c, d, a, b, x[k + 7], S23, 0x676F02D9);
                b = GG(b, c, d, a, x[k + 12], S24, 0x8D2A4C8A);
                a = HH(a, b, c, d, x[k + 5], S31, 0xFFFA3942);
                d = HH(d, a, b, c, x[k + 8], S32, 0x8771F681);
                c = HH(c, d, a, b, x[k + 11], S33, 0x6D9D6122);
                b = HH(b, c, d, a, x[k + 14], S34, 0xFDE5380C);
                a = HH(a, b, c, d, x[k + 1], S31, 0xA4BEEA44);
                d = HH(d, a, b, c, x[k + 4], S32, 0x4BDECFA9);
                c = HH(c, d, a, b, x[k + 7], S33, 0xF6BB4B60);
                b = HH(b, c, d, a, x[k + 10], S34, 0xBEBFBC70);
                a = HH(a, b, c, d, x[k + 13], S31, 0x289B7EC6);
                d = HH(d, a, b, c, x[k + 0], S32, 0xEAA127FA);
                c = HH(c, d, a, b, x[k + 3], S33, 0xD4EF3085);
                b = HH(b, c, d, a, x[k + 6], S34, 0x4881D05);
                a = HH(a, b, c, d, x[k + 9], S31, 0xD9D4D039);
                d = HH(d, a, b, c, x[k + 12], S32, 0xE6DB99E5);
                c = HH(c, d, a, b, x[k + 15], S33, 0x1FA27CF8);
                b = HH(b, c, d, a, x[k + 2], S34, 0xC4AC5665);
                a = II(a, b, c, d, x[k + 0], S41, 0xF4292244);
                d = II(d, a, b, c, x[k + 7], S42, 0x432AFF97);
                c = II(c, d, a, b, x[k + 14], S43, 0xAB9423A7);
                b = II(b, c, d, a, x[k + 5], S44, 0xFC93A039);
                a = II(a, b, c, d, x[k + 12], S41, 0x655B59C3);
                d = II(d, a, b, c, x[k + 3], S42, 0x8F0CCC92);
                c = II(c, d, a, b, x[k + 10], S43, 0xFFEFF47D);
                b = II(b, c, d, a, x[k + 1], S44, 0x85845DD1);
                a = II(a, b, c, d, x[k + 8], S41, 0x6FA87E4F);
                d = II(d, a, b, c, x[k + 15], S42, 0xFE2CE6E0);
                c = II(c, d, a, b, x[k + 6], S43, 0xA3014314);
                b = II(b, c, d, a, x[k + 13], S44, 0x4E0811A1);
                a = II(a, b, c, d, x[k + 4], S41, 0xF7537E82);
                d = II(d, a, b, c, x[k + 11], S42, 0xBD3AF235);
                c = II(c, d, a, b, x[k + 2], S43, 0x2AD7D2BB);
                b = II(b, c, d, a, x[k + 9], S44, 0xEB86D391);
                a = addUnsigned(a, AA);
                b = addUnsigned(b, BB);
                c = addUnsigned(c, CC);
                d = addUnsigned(d, DD);
            }
            var tempValue = wordToHex(a) + wordToHex(b) + wordToHex(c) + wordToHex(d);
            return tempValue.toLowerCase();
        }
    });
})(jQuery);

//#endregion

//#region Object扩展方法
function getXML(jsonObj, root) {
    /// <summary>
    /// 将一个JSON对象转换为XML格式的字符串
    /// </summary>
    /// <param name="jsonObj" type="type"></param>
    /// <param name="root" type="type"></param>
    /// <returns type=""></returns>
    var xml = "";
    if (jsonObj instanceof Array) {
        for (var i = 0; i < jsonObj.length; i++) {
            xml += getXML(jsonObj[i], true);
        }
        return "<xml>" + xml + "</xml>";
    } else {
        for (var f in jsonObj) {
            if (jsonObj[f] && jsonObj.hasOwnProperty(f)) {
                xml += toXml(jsonObj[f], f, "");
            }
        }
    }
    if (!root) {
        xml = "<xml>" + xml.replace(/\t|\n/g, "") + "</xml>";
    } else {
        xml = xml.replace(/\t|\n/g, "");
    }

    return xml;
};

function toXml(v, name, ind) {
    var xml = "";
    if (v instanceof Array) {
        for (var i = 0, n = v.length; i < n; i++) xml += ind + toXml(v[i], name, ind + "\t") + "\n";
    } else if (typeof v == "object") {
        var hasChild = false;
        xml += ind + "<" + name;
        for (var m in v) {
            if (m.charAt(0) == "@") xml += " " + m.substr(1) + "=\"" + v[m].toString().replace(/</g, "&lt;").replace(/>/g, "&gt;").replace(/"/g, "&quot;").replace(/\'/g, " &apos;").replace(/&/g, '&amp;') + "\""; else hasChild = true;
        }
        xml += hasChild ? ">" : "/>";
        if (hasChild) {
            for (var m in v) {
                if (m == "#text") xml += v[m]; else if (m == "#cdata") xml += "<![CDATA[" + v[m] + "]]>"; else if (m.charAt(0) != "@") xml += toXml(v[m], m, ind + "\t");
            }
            xml += (xml.charAt(xml.length - 1) == "\n" ? ind : "") + "</" + name + ">";
        }
    } else if (typeof v == "function") {
        return "";
    } else if (v !== undefined && v !== null) {
        xml += ind + "<" + name + ">" + v.toString().replace(/</g, "&lt;").replace(/>/g, "&gt;").replace(/"/g, "&quot;").replace(/\'/g, " &apos;").replace(/&/g, '&amp;') + "</" + name + ">";
    } else { }
    return xml;
};

function errFormate(rtn, withSrc) {
    /// <summary>
    /// 根据前端配置格式化含有错误信息的标准返回结果
    /// </summary>
    if (rtn.IsPositive) {
        return "";
    }
    if (!window.RES || !RES.ERROR || !RES.ERROR[rtn.ErrorSrc]) {
        if (withSrc) {
            return {
                msg: "错误代码[" + rtn.ErrorCode + "]",
                from: "来自：" + rtn.ErrorSrc
            }
        }
        else {
            return "服务器组件&lt;" + rtn.ErrorSrc + "&gt;返回了错误代码[" + rtn.ErrorCode + "]";
        }

    }
    else {
        var er = RES.ERROR[rtn.ErrorSrc];
        if (er[rtn.ErrorCode]) {
            if (!withSrc) {
                return er[rtn.ErrorCode];
            }
            else {
                return {
                    msg: er[rtn.ErrorCode],
                    from: "来自：" + er.ErrSrc
                }
            }
        }
        else {
            if (!withSrc) {
                return "服务器返回了一个错误，但没有说明具体原因";
            }
            else {
                return {
                    msg: "服务器返回了一个错误，但没有说明具体原因",
                    from: "系统"
                }
            }
        }
    }
};

JSON.merge = function (targetObj, fromObj,excludeNewProp) {
    /// <summary>
    /// 深度合并目标Json对象到指定的Json对象
    /// </summary>
    /// <param name="targetObj" type="type">合并目标</param>
    /// <param name="fromObj" type="type">合并来源，如果有相同属性，将覆盖目标对象中的值</param>
    /// <param name="excludeNewProp" type="boolean">是否排除目标对象本来没有的属性</param>

    if (!targetObj || !fromObj || !targetObj instanceof Object || !targetObj instanceof Object) {
        return targetObj;
    };

    if (fromObj instanceof Array && targetObj instanceof Array) {
        for (var i = 0; i < fromObj.length; i++) {
            if (fromObj[i] instanceof Object && targetObj[i]) {
                targetObj[i] = JSON.clone(fromObj[i]);
            }
            else {
                targetObj[i] = fromObj[i];
            }
        }
    }
    else {
        for (var p in fromObj) {
            if (targetObj.hasOwnProperty(p) && targetObj[p] instanceof Object) {
                targetObj[p] = JSON.clone(fromObj[p]);
            }
            else if (!excludeNewProp) {
                targetObj[p] = fromObj[p];
            }
            else {

            }
        }
    }
    return targetObj;
};

JSON.clone = function (obj) {
    if (!obj || !obj instanceof Object) {
        return obj;
    }
    return JSON.parse(JSON.stringify(obj));
};

function isSame (a,b) {
    if (!a||!b) {
        return false;
    }
    var astr = JSON.stringify(a).split('').sort().toString();
    var bstr = JSON.stringify(b).split('').sort().toString();
    return astr === bstr;
};

//#endregion

//#region Number对象的扩展方法
Number.prototype.roundTo = function (fix) {
    /// <summary>
    /// 高精度四舍五入到指定位数
    /// </summary>
    /// <param name="fix"></param>
    return Math.round(this * Math.pow(10, fix)) / Math.pow(10, fix);
};
Number.prototype.formatPercent = function (fix, noceil) {
    /// <summary>
    /// 带百分号，并可以指定小数部分的位数
    /// </summary>
    /// <param name="fix" type="type">小数位最大长度</param>
    /// <param name="noceil" type=boolean>如果小数位部分太小，是否在最后一位上进位表达[默认进位]</param>
    /// <returns type=""></returns>
    if (fix === undefined || fix === null) {
        fix = 0;
    };

    var fStr = (this * 100).toString();
    var dot = fStr.indexOf('.');

    if (dot < 0) {
        return fStr + '%';
    }
    else {
        var pStr = fStr.substring(0, dot);
        var eStr = "0." + fStr.substring(dot + 1, fStr.length);
        var eValue = Math.floor(parseFloat(eStr) * Math.pow(10, fix));
        if (eValue == 0 && !noceil) {
            return pStr + "." + (1).fixLength(fix) + "%";
        }
        else {
            return pStr + "." + eValue.fixLength(fix) + "%";
        }

    }
};
Number.prototype.toThousands = function (fix) {
    /// <summary>
    /// 将数字按千分位分隔符
    /// </summary>
    /// <param name="fix" type="type">小数位固定长度</param>
    /// <returns type=""></returns>
    var src = (this || 0).toString().split('.');
    var num = src[0];
    var result = "";
    if (src.length > 1) {
        if (fix === undefined || fix === null || !parseInt(fix)) {
            result = '.' + src[1];
        }
        else {
            var tail = parseFloat('0.' + src[1]).toFixed(fix);
            result = '.' + tail.split('.')[1];
        }
    }

    while (num.length > 3) {
        result = ',' + num.slice(-3) + result;
        num = num.slice(0, num.length - 3);
    }
    if (num) {
        result = num + result;
    }
    if (src.length == 1 && fix !== undefined && fix !== null && parseInt(fix)) {
        var tail = (1.0).toFixed(fix);
        result = result + '.' + tail.toString().split('.')[1];
    }
    return result;
};
Number.prototype.fixLength = function (len) {
    /// <summary>
    /// 将数字格式化为固定长度的字符串[前缀补0]
    /// </summary>
    /// <param name="len" type="type"></param>
    /// <returns type=""></returns>
    var ln = this.toString().length;
    var num = this;
    while (ln < len) {
        num = "0" + num;
        ln += 1;
    }
    return num;
};
//#endregion

//#region 日期对象的扩展方法
Date.prototype.formate = function (parten) {
    if (!parten) {
        parten = "yyyy-MM-dd HH:mm:ss";
    };

    var o = {
        "M+": this.getMonth() + 1,                 /*月份 */
        "d+": this.getDate(),                    /*日 */
        "h+": this.getHours(),                   /*小时*/
        "H+": this.getHours(),
        "m+": this.getMinutes(),                 /*分 */
        "s+": this.getSeconds(),                 /*秒 */
        "q+": Math.floor((this.getMonth() + 3) / 3), /*季度 */
        "S": this.getMilliseconds()             /*毫秒*/
    };
    if (/(y+)/.test(parten)) {

        parten = parten.replace(RegExp.$1, (this.getFullYear() + "").substr(4 - RegExp.$1.length));
    }
    for (var k in o) {
        if (new RegExp("(" + k + ")").test(parten)) {
            parten = parten.replace(RegExp.$1, (RegExp.$1.length == 1) ? (o[k]) : (("00" + o[k]).substr(("" + o[k]).length)));
        }
    }
    return parten;

}
Date.prototype.diffOf = function (startDate) {
    /// <summary>
    /// 获取当前时间与起始时间的大致间隔
    /// </summary>
    /// <param name="startDate" type="Date"></param>
    if (startDate === undefined || startDate === null) {
        startDate = new Date();
    }
    else if (!(startDate instanceof Date)) {
        startDate = new Date(startDate);
    }
    else {
    };

    let rtn = {
        year: 0,
        month: 0,
        day: 0,
        hour: 0,
        min: 0,
        second: 0
    };

    let tickets = this.getTime() - startDate.getTime();   //时间差的毫秒数        

    //计算出总计相差  
    rtn.day = Math.floor(tickets / (24 * 3600 * 1000));
    rtn.year = this.getYear() - startDate.getYear();
    rtn.month = rtn.year * 12 + (this.getMonth() - startDate.getMonth());
    if (rtn.month < 12 && rtn.year < 0) {
        rtn.year += 1;
    };

    if (rtn.day < 30 && rtn.month < 0) {
        rtn.month += 1;
    };

    /*计算天数后剩余的毫秒数*/
    let leftTickts = tickets % 86400000;
    rtn.hour = Math.floor(leftTickts / 3600000);
    if (rtn.hour < 0) {
        rtn.hour += rtn.day * -24;
    }
    
    //rtn.day += 1;  /*加上当天修正*/

    /*计算小时数后剩余的毫秒数*/
    leftTickts = leftTickts % 3600000;
    rtn.min = Math.floor(leftTickts / 60000);

    /*计算分钟数后剩余的毫秒数*/
    leftTickts = leftTickts % 60000;
    rtn.second = Math.floor(leftTickts / 1000);

    return rtn;
};
Date.prototype.addDays = function (d) {
    if (d && $.isNumeric(d)) {
        var nt = (d * 86400000) + this.getTime();
        return new Date(nt);
    }
    else {
        return this;
    }
};
//#endregion

//#region 用数组模拟的双向队列
function Queue(srcArray) {
    var elms = (srcArray && Array.isArray(srcArray)) ? srcArray : [];

    this.Append = function (obj) {
        /// <summary>
        /// 向队列尾部追加一个元素
        /// </summary>
        /// <param name="obj"></param>
        /// <returns type="Queue"></returns>
        elms.push(obj);
        return this;
    };

    this.Prepend = function (obj) {
        /// <summary>
        /// 向队列头部插入一个元素
        /// </summary>
        /// <param name="obj"></param>
        /// <returns type="Queue"></returns>
        var tmp = [obj];
        elms = tmp.concat(elms);
        return this;
    };

    this.Dequeue = function () {
        /// <summary>
        /// 移除并返回队列头部的元素
        /// </summary>
        if (elms.length > 0) {
            return elms.shift();
        } else {
            return null;
        }
    };

    this.Length = function () {
        return elms.length;
    };
    return this;
};

//#endregion

//全站基础UI逻辑
if (!window.SoBiz) {
    window.RQList = {};
    window.url_parser = new RegExp(/(\/[\S\s]*)\??([\S]*)#?([\S]*?)/gi);
    $.ajaxSetup({
        cache: true,
        async: true,
        timeout: 60000,
        contentType: "application/x-www-form-urlencoded; charset=utf-8",
        xhr: function () {
            var x = new XMLHttpRequest();
            x.withCredentials = true;
            this.rawXHR = x;
            return x;
        },
        beforeSend: function beforeSend(rq, ev) {
            //针对html和JSON请求判断动作权限
            var dtype = ev.dataType ? ev.dataType.toLowerCase() : "";
            var uri = document.createElement('a');
            uri.href = ev.url;

            var path = uri.pathname.toLowerCase();
            //针对IE有时pathname会没有前面的斜杠进行处理
            if (path.substr(0, 1) !== '/') {
                path = '/' + path;
            };

            if ((dtype == "html" || dtype == "json")) {
                console.log("TODO:对于html请求和json请求进行基于URL的权限筛选");
                //对于html请求和json请求进行基于URL的权限筛选
            };


            //阻止重复的POST提交
            if (this.type == "POST" && (RQList[path] != null && RQList[path] == 1)) {
                console.log("抱歉，此操作禁止重复执行，请等待前次请求执行完毕" + path);
                rq.abort();
                return false;
            }
            else if (this.type == "POST" && this.data && this.data.indexOf("_alone=false") == -1) {
                //如果首次POST请求，且未指定关闭独占模式，添加到监视列表
                RQList[path] = 1;
                this._rootPath = path;
            }
            else {
            }

            //为POST请求增加额外的验证头
            if (this.type == "POST" && $.Cookie("liber_session")) {
                rq.setRequestHeader("X-Liber-ClientID", $.Cookie("liber_session").MD5());
            }

            //TODO:对于一模一样的Get请求进行限流处理
        },
        complete: function complete(rtn, ev) {
            if (this._rootPath) {
                RQList[this._rootPath] = -1;
            }
        },
        error: function (rtn, er) {
            if (this._rootPath) {
                RQList[this._rootPath] = -1;
            }
        }
    });

    //业务对象标准生存周期状态
    window.BizStatus = {
        Unknow: -1,
        Draft: 1,
        Active: 2,
        Aborted: 3,
        Completed: 4,
        Pending: 5,
        getString: function (s) {
            switch (s) {
                case 0:
                    return 'Unknow';
                case 1:
                    return 'Draft';
                case 2:
                    return 'Active';
                case 3:
                    return 'Aborted';
                case 4:
                    return 'Completed';
                case 5:
                    return 'Pending';
                default:
                    return '';
            }
        },
        fromString: function (str) {
            switch (str.toLowerCase()) {
                case 'draft':
                    return 1;
                case 'active':
                    return 2;
                case 'aborted':
                    return 3;
                case 'completed':
                    return 4;
                case 'pending':
                    return 5;
                default:
                    return -1;
            }
        }
    };
    Vue.prototype.BizStatus = window.BizStatus;

    window.SoBiz = {
        SessionID: function (fnOnSuccess) {
            /// <summary>
            /// 获取当前客户端的唯一标识
            /// </summary>
            /// <param name="fnOnSuccess" type="function">回调方法</param>
            if (!$.Cookie("liber_session")) {
                $.ajax({
                    url: "/api/SoBiz/NewSession",
                    type: "GET",
                    success: function () { fnOnSuccess && fnOnSuccess($.Cookie("liber_session")); },
                    error: SoBiz.onNetFail
                });
            }
            else {
                fnOnSuccess && fnOnSuccess($.Cookie("liber_session"));
            }
        },
        NewSession: function (fn) {
            $.Cookie("liber_session", null);
            $.ajax({
                url: "/api/SoBiz/NewSession",
                type: "GET",
                success: function () { fn && fn($.Cookie("liber_session")); },
                error: SoBiz.onNetFail
            });
        },
        GetJSON: function (url, param, onSuccess, onErr) {
            /// <summary>
            /// 封装JQ的ajax请求JSON方法，提供错误回调
            /// </summary>
            /// <param name="url" type="type"></param>
            /// <param name="param" type="type"></param>
            /// <param name="onSuccess" type="type"></param>
            /// <param name="onErr" type="type">网络请求失败处理【不提供，则采用默认处理方式，401会转入登录页】</param>
            return $.ajax({
                url: "/api" + url,
                type: 'GET',
                dataType: 'json',
                data: param,
                success: onSuccess,
                error: onErr || SoBiz.onNetFail
            });
        },
        Any: function () {
            return new SoBiz.taskmng();
        },
        POST: function (url, upData, onSuccess, onErr, _alone, rspType) {
            /// <summary>
            /// 封装JQ的ajax请求POST方法，提供失败回调
            /// </summary>
            /// <param name="url" type="string"></param>
            /// <param name="upData" type="json|string"></param>
            /// <param name="onSuccess" type="function"></param>
            /// <param name="onErr" type="function">网络请求失败处理【不提供，则采用默认处理方式，401会转入登录页】</param>
            /// <param name="_alone" type="boolean">默认POST请求采用独占模式，不允许重复提交，如果有需要，可设置此参数为false</param>
            /// <param name="rspType" type="string">自定义返回的数据类型</param>
            if (!upData) {
                upData = {};
            }

            upData._alone = _alone ? _alone : true;
            var opt = {
                url: "/api" + url,
                type: 'POST',
                data: upData,
                cache: false,
                success: function (rtn, status, xhr) {
                    if (this.rawXHR && (this.rawXHR.responseType == 'blob' || this.rawXHR.responseType == 'arraybuffer')) {
                        var hrs = xhr.getAllResponseHeaders();
                        var cc = hrs.match(/(content-disposition:).*(\s)/g);
                        var fname = "下载文档";
                        if (cc && cc.length > 0) {
                            var tf = cc[0].trim().match(/(filename%3d)+.*$/g);
                            if (tf && tf.length > 0) {
                                tf[0] = tf[0].replace("filename%3d", "");
                                fname = decodeURIComponent(decodeURIComponent(tf[0].trim()));
                            }
                        }
                        if (this.rawXHR.response && this.rawXHR.response.size > 0) {
                            rtn = {
                                IsPositive: true,
                                Data: this.rawXHR.response
                            }
                            var fileUrl = URL.createObjectURL(this.rawXHR.response);
                            var a = document.createElement("a");
                            document.body.appendChild(a);
                            a.style = "display: none";
                            a.href = fileUrl;
                            a.setAttribute("exp", "true");
                            try {
                                a.download = fname;
                                a.click();
                            }
                            catch (ex) {
                                window.navigator.msSaveBlob(this.rawXHR.response, fname);
                            }
                            document.body.removeChild(a);
                            URL.revokeObjectURL(fileUrl);
                        }
                        else {
                            rtn = {
                                IsPositive: false,
                                ErrorCode: 'BadResponse',
                                ErrorSrc: 'System'
                            }
                        }
                    };
                },
                xhrFields: {
                    responseType: rspType
                },
                error: onErr || SoBiz.onNetFail
            };
            $.ajax(opt);
        },
        Connect: function (doMsg) {
            /// <summary>
            /// 创建一个长连接到实时消息服务器
            /// </summary>
            /// <params name="doMsg" type="function">接收到消息的处理方法</params>

            //根据浏览器能力使用轮询或WebSocket
            if (SoBiz.CONNECTOR.ready) {
                SoBiz.CONNECTOR.onmessage(doMsg);
            }
            else if (window.WebSocket && window.WebSocket.prototype.send) {
                JSON.merge(SoBiz.CONNECTOR, new SoBiz.wsconnector());
                SoBiz.CONNECTOR.onmessage(doMsg);

                window.addEventListener("beforeunload", function () {
                    if (SoBiz.CONNECTOR) {
                        SoBiz.CONNECTOR.dispose();
                        SoBiz.CONNECTOR = null;
                    }
                });
            }
            else {
                JSON.merge(SoBiz.CONNECTOR, new SoBiz.httpconnector());
                SoBiz.CONNECTOR.onmessage(doMsg);
            }
        },
        onNetFail: function (ev) {
            /// <summary>
            /// 通用网络错误处理
            /// </summary>
            /// <param name="ev" type="type"></param>
            if (ev.status == 401) {
                err("会话过期", "为了保护数据安全，我们需要重新验证您的身份", 5, SoBiz.LoginOut());
            }
            else if (ev.status == 403) {
                err("权限不足", "对不起，您的帐号缺少此操作所需的相应权限", 5, function () {
                    window.history.go(-1);
                });
            }
            else if (ev.status == 500) {
                //TODO:通用Debug方法发回给服务器
                SoBiz.Debug(this.url + "?" + this.data, "ServerCrash");
                err("抱歉", "服务器无法处理您的请求，我们已记录并通知管理人员，请您稍后再试");
            } else if (ev.status == 0 && ev.statusText.toLowerCase() == "timeout") {
                SoBiz.Debug(this.url + "?" + this.data, "Timeout");
                err("抱歉", "大家太热情了，服务器有点忙不过来，请您稍后再试");
            }
            else if (navigator.onLine == false) {
                err("网络故障", "无法连接到服务器，请检查网络连接情况");
            }
            else if (ev.status == 0 && ev.statusText.toLowerCase() == "error") {
                err("服务器无响应", "平台维护中，暂时无法响应您的请求");
            }
            else {
            }
        },
        User: {
            _ready: false,
            name: '',
            mphone: '',
            headimg: '#',
            mphoneStr: '-',
            ex_mphones: []
        },
        TMP: {},
        Login: function (onSuccess, onFail) {
            /// <summary>
            /// 检查当前登录状态
            /// </summary>
            /// <param name="onSuccess" type="function">标准事件回调，在登录成功后触发，返回对象包含基础用户信息</param>
            /// <param name="onFail" type="function">网络请求失败或登录失败</param>

            //判断本地登录状态
            var ut = $.Cookie("uTicket");
            if (!ut) {
                onFail ? onFail() : SoBiz.LoginOut();
                return;
            }
            else {
                var n = ut.match(/&name=(\S*?)&/);
                var m = ut.match(/&mphone=(\S*?)&/);
                var h = ut.match(/&headimg=(\S*?)$/);
                SoBiz.User.name = n && n.length > 0 ? decodeURIComponent(n[1]) : '请登录';
                SoBiz.User.mphone = m && m.length > 0 ? m[1] : "-";
                SoBiz.User.headimg = h && h.length > 0 && h[1].length > 1 ? decodeURIComponent(atob(h[1])) : "/ui/imgs/default-user-headimg.jpg";
                onSuccess && onSuccess(SoBiz.User);
                return;
            }
        },
        GetUser: function (onSuccess) {
            if (SoBiz.User._ready) {
                onSuccess && onSuccess(SoBiz.User);
                return SoBiz.User;
            }
            $$.GetJSON("/My/GetUser", null, function (rtn) {
                if (rtn.IsPositive) {
                    if (!rtn.Data.headimg) {
                        rtn.Data.headimg = '/ui/imgs/default-user-headimg.jpg';
                    };
                    rtn.Data.createtime = new Date(rtn.Data.createtime);
                    rtn.Data.mphoneStr = rtn.Data.mphone.substr(0, 3) + "****" + rtn.Data.mphone.substr(7);
                    SoBiz.User._ready = true;
                    JSON.merge(SoBiz.User, rtn.Data);
                    onSuccess && onSuccess(SoBiz.User);
                    return SoBiz.User;
                }
            });
        },
        SSOProcess: function (sites) {
            /*处理单点登录*/
            var su = $.Cookie("ssologout");
            if (su) {
                /*SSO登出其他子站*/
                $.Cookie("ssologout", "del", { expires: -1, path: '/' });
                if (sites) {
                    sites.forEach(function (u) {
                        $.ajax({
                            url: u + "/api/SoBiz/Logout",
                            crossDomain: true,
                            withCredentials: true,
                            dataType: 'jsonp'
                        });
                    });
                };
            }
            else {
                var sl = $.Cookie("ssologin");
                var ut = $.Cookie("uTicket");
                if (!sl && ut && sites) {
                    /*SSO登录其他子站*/
                    $.Cookie("ssologin", "begin", { expires: 1000, path: '/' });
                    setTimeout(function () {
                        $.getJSON("/api/SoBiz/SSOBegin", function (rtn) {
                            if (rtn.IsPositive) {
                                sites.forEach(function (u) {
                                    if (u.split("//")[1] !== window.location.host) {
                                        $.ajax({
                                            url: u + "/api/SoBiz/SSOLogin?ut=" + rtn.Data,
                                            crossDomain: true,
                                            dataType: 'jsonp',
                                            //async: false,
                                            type: 'GET'
                                        });
                                    }
                                });
                            }
                        });
                        $.Cookie("ssologin", "del", { expires: -1, path: '/' });
                    }, 1000);
                }
            }
        },
        LoginOut: function () {
            $.Cookie("ssologout", "true", { expires: 2, path: '/' });
            $.Cookie("uTicket", "loginout", { expires: -1, path: '/' });
            $$.User._ready = false;
            $$.POST("/CloudAdmin/ClearAcntCache", null, function () {
                location = "/";
            });

        },
        LoadVue: function (url, name) {
            var f = function (resolve) {
                $.ajax({
                    url: url,
                    dataType: 'html',
                    success: function (rtn) {
                        var cnt = $(rtn);
                        var id = url.hashCode();
                        var vueOpt = {
                            template: '',
                            _js: [],
                            _styles: [],
                            _id: id,
                            _jsDelay: 0
                        };

                        cnt.each(function (i) {
                            switch (this.nodeName.toLowerCase()) {
                                case "link":
                                    var oldLnk = $(document.head).children("[href='" + this.getAttribute("href") + "']");
                                    if (oldLnk.length > 0) {
                                        appendRefer(oldLnk[0], id);
                                    }
                                    else {
                                        this.setAttribute("reference", id);
                                        document.head.appendChild(this);
                                    }
                                    vueOpt._styles.push(this.getAttribute("href"));
                                    break;
                                case "script":
                                    var csrc = this.getAttribute("src")
                                    if (csrc) {
                                        var oldJS = $(document.head).children("[src='" + csrc + "']");
                                        if (oldJS.length > 0) {
                                            appendRefer(oldJS[0], id);
                                        }
                                        else {
                                            if (this.attr("async")) {
                                                vueOpt._jsDelay += 1;
                                                this.onload = function (arg) {
                                                    /*同步js文件在加载完毕后检查并回调Vue的组件构造函数*/
                                                    arg._jsDelay -= 1;
                                                    if (arg._jsDelay == 0) {
                                                        resolve(arg);
                                                    }
                                                }.bind(this, vueOpt);
                                            };
                                            $(document.head).append(this);
                                        };
                                        vueOpt._js.push(csrc);
                                    }
                                    else {
                                        JSON.merge(vueOpt, eval(this.innerText));
                                    }
                                    break;
                                case "template":
                                    vueOpt.template = this.innerHTML;
                                    break;
                                default:
                                    break;
                            }
                        });

                        /*添加mounted和destroy事件监控，处理相关样式和脚本*/
                        //var o_mounted = vueOpt.mounted;
                        if (!vueOpt.methods) {
                            vueOpt.methods = {}
                        }
                        vueOpt.methods._mounted = vueOpt.mounted || function () { };
                        vueOpt.mounted = function (ev) {
                            /*恢复此vue组件所引入的样式和脚本*/
                            vueOpt._styles.forEach(function (n) {
                                var lnk = $(document.head).children("[href='" + n + "']");
                                if (lnk.length == 0) {
                                    var s = $("<link>").attr("href", n).attr("rel", "stylesheet").attr("reference", vueOpt._id);
                                    document.head.appendChild(s[0]);
                                };
                            });
                            vueOpt._js.forEach(function (n) {
                                var lnk = $(document.head).children("[src='" + n + "']");
                                if (lnk.length == 0) {
                                    var s = $("<script>").attr("src", n).attr("reference", vueOpt._id);
                                    $(document.head).append(s);
                                };
                            });
                            this._mounted();
                            //o_mounted && o_mounted.call(this);
                        };

                        var o_beforeDestroy = vueOpt.beforeDestroyed;
                        vueOpt.beforeDestroy = function (ev) {
                            /*将此vue组件所引入的样式和脚本清除*/
                            vueOpt._styles.forEach(function (n) {
                                var lnk = $(document.head).children("[href='" + n + "']");
                                reduceRefer(lnk[0], vueOpt._id);
                            });
                            vueOpt._js.forEach(function (n) {
                                var lnk = $(document.head).children("[src='" + n + "']");
                                reduceRefer(lnk[0], vueOpt._id);
                            });
                            o_beforeDestroy && o_beforeDestroy.call(this);
                        };

                        if (vueOpt._jsDelay == 0) {
                            resolve(vueOpt);
                        }
                        cnt = null;
                    }
                });
            };

            Vue.component(name, f);
        },
        LoadView: function (elm, url) {
            /// <summary>
            /// 加载指定页面内容并替换到指定容器元素中
            /// </summary>
            /// <param name="elm" type="Dom and JQuery Object">要替换的容器元素或选择器</param>
            /// <param name="url" type="String">要加载的页面地址</param>
            elm = $(elm).first();
            if (elm.length == 0) {
                return;
            };
            var id = url.hashCode();
            var oid = elm.attr("cntid");

            if (!oid) {
                //没有旧内容，不用处理
            }
            else if (oid !== id) {
                //清理旧的DOM内容(页面动态添加到body下的元素)
                $('body').children().each(function (c) {
                    var cid = this.getAttribute("cntid");
                    if (!cid || (this.nodeName.toLowerCase() == "script" && cid == oid)) {
                        this.parentNode.removeChild(this);
                    }
                });
                //更新在head中的引用资源的被使用情况
                if (document.head.childNodes.forEach) {
                    document.head.childNodes.forEach(function (n) {
                        reduceRefer(n, oid);
                    });
                }
                else {
                    $(document.head).children().each(function (n) {
                        reduceRefer(this, oid);
                    });
                }
            }
            else {
                return;
            }

            elm.attr("cntid", id);
            elm.html("");
            elm.appendTo(elm.parent()[0]);

            elm.mask().addClass("CntLoading");
            $.ajax({
                url: url,
                dataType: 'html',
                success: function (rtn) {
                    var cnt = $(rtn);
                    var tmp = {
                        delay: 0
                    };
                    var tmpJS = [];
                    tmp.delay = cnt.filter("script").length;
                    cnt.each(function (i) {
                        switch (cnt[i].nodeName.toLowerCase()) {
                            case "link":
                                var oldLnk = $(document.head).children("[href='" + cnt[i].getAttribute("href") + "']");
                                if (oldLnk.length > 0) {
                                    appendRefer(oldLnk[0], id);
                                }
                                else {
                                    cnt[i].attr("reference", id);
                                    document.head.appendChild(cnt[i]);
                                }
                                break;
                            case "script":
                                var csrc = cnt[i].getAttribute("src");
                                if (csrc) {
                                    var oldJS = $(document.head).children("[src='" + csrc + "']");
                                    if (oldJS.length > 0) {
                                        tmp.delay -= 1;
                                        appendRefer(oldJS[0], id);
                                    }
                                    else {
                                        var script = document.createElement('script');
                                        script.type = 'text/javascript';
                                        script.src = csrc;
                                        script.setAttribute("reference", id);
                                        script.onload = function (js, arg) {
                                            arg.delay -= 1;
                                            if (arg.delay <= 0) {
                                                var bd = $(document.body);
                                                for (var i = 0; i < js.length; i++) {
                                                    bd.append(js[i]);
                                                };
                                            };
                                        }.bind(this, tmpJS, tmp);
                                        document.head.appendChild(script);
                                    }
                                }
                                else {
                                    tmp.delay -= 1;
                                    cnt[i].setAttribute("cntid", id);
                                    tmpJS.push(cnt[i]);
                                }
                                break;
                            case "title":
                                document.title = cnt[i].text;
                                break;
                            case "auth":
                                /*根据页面上的anth标签处理权限（secLv,admin,auth）,如何给错误提示页面传递所需的授权信息呢？*/
                                $(elm).load("/Error/noauth.html");
                                break;
                            case "meta":
                            case "#text":
                                break;
                            default:
                                elm[0].appendChild(cnt[i]);
                                break;
                        }
                    });
                    if (tmp.delay <= 0) {
                        var bd = $(document.body);
                        for (var i = 0; i < tmpJS.length; i++) {
                            bd.append(tmpJS[i]);
                        };
                    }
                    elm.unmask(true);
                    cnt = null;
                    tmpJS = null;
                    elm.find("._checkon").each(function () {
                        var pe = $(this);
                        if (pe.data("checker") === undefined) {
                            pe.data("checker", new LiberUI.InputChecker(elm));
                        }
                    });
                }
            });
        },
        Load: function (ev) {
            /// <summary>
            /// 基于前端路由技术的框架式加载技术
            /// </summary>
            var path;
            var route;
            if (RES.RouteTable) {
                /*检测路由，重写浏览器地址栏信息*/
                var cpath = window.location.pathname.toLowerCase();
                var chash = window.location.hash.toLowerCase();
                for (var r in RES.RouteTable) {
                    if (cpath.indexOf(r) > -1) {
                        path = cpath;
                        //针对IE有时pathname会没有前面的斜杠进行处理
                        if (path.substr(0, 1) !== '/') {
                            path = '/' + path;
                        };
                        route = RES.RouteTable[r];
                        break;
                    }
                    else if (chash.indexOf(r) > -1) {
                        path = chash.substring(1);
                        route = RES.RouteTable[r];
                        if (window.location.search) {
                            path = path + window.location.search.substring(1);
                        }
                       
                        break;
                    }
                    else {
                    }
                }
            };

            if (!path || !route) {
                window.location = "/Error/404.html";
                return;
            };

            ev && ev.preventDefault() && ev.stopPropagation();

            /*切换模板，重新加载所有页面*/
            if (route.template && SoBiz.Page && SoBiz.Page.template !== route.template) {
                if (SoBiz.CONNECTOR) {
                    SoBiz.CONNECTOR.dispose();
                };
                window.location = route.template + "#" + path;
                window.localStorage.removeItem("_page");
                return;
            };

            /*初始化一个待加载内容列表*/
            var tmp = [];

            //模板初始化
            if (!SoBiz.Page.TMP) {
                /*完全重新加载*/
                $(document.body).undelegate("a[href!='#'][exp!='true']", 'click');
                /*拦截所有a链接跳转和地址栏变动行为，改为模板加载*/
                $(document.body).delegate("a[href!='#'][exp!='true']", "click", function (ev) {
                    var lnk = this.getAttribute("href");
                    if (!lnk) {
                        return false;
                    }
                    lnk = lnk.toLowerCase();
                    if (lnk.indexOf(".html") == -1) {
                        window.history.pushState ? window.history.pushState(null, "", lnk) : window.location.hash = lnk;
                        SoBiz.Load(ev);
                        return false;
                    };
                });

                if (!window.onpopstate) {
                    window.onpopstate = SoBiz.Load;
                    window.onhashchange = SoBiz.Load;
                }

                window.history.replaceState(null, "", path);
                SoBiz.Page.template = r.template || '/ui/normal.html';
                SoBiz.Page.Section = {};
                SoBiz.Page.TMP = {};
            };

            window.postMessage("locationChanged", "/");

            $("body").find("[section]").each(function (s) {
                SoBiz.Page.Section[this.getAttribute("section")] = { domid: "#" + this.ID(), url: '' };
            });

            //处理模板公共区域
            for (var s in route.section) {
                if (SoBiz.Page.Section[s] && SoBiz.Page.Section[s].url != route.section[s]) {
                    tmp.push({
                        elm: SoBiz.Page.Section[s].domid,
                        url: route.section[s]
                    });
                }
            };

            //处理当前页面的个性化区域
            for (var m in route.map) {
                if (0==path.indexOf(m) && m.indexOf('*') == -1) {
                    var croute = route.map[m];
                    for (var s in croute) {
                        if (SoBiz.Page.Section[s] && SoBiz.Page.Section[s].url != croute[s]) {
                            tmp.push({
                                elm: SoBiz.Page.Section[s].domid,
                                url: croute[s]
                            });
                        }
                    }
                    break;
                }
            };

            //执行动态加载
            for (var i = 0; i < tmp.length; i++) {
                SoBiz.LoadView(tmp[i].elm, tmp[i].url);
            };
            return SoBiz.Page;
        },
        Page: {
            template: '/ui/normal.html',
            Section: {}
        },
        _eventHandlers: {},

        on: function (event, fnCallback) {
            /// <summary>
            /// 绑定全局状态事件
            /// </summary>
            /// <param name="event" type="type"></param>
            /// <param name="fnCallback" type="type"></param>
            if (!SoBiz._eventHandlers[event]) {
                SoBiz._eventHandlers[event] = [];
            }
            SoBiz._eventHandlers[event].push(fnCallback);
            return SoBiz;
        },

        off: function (event, fnCallback) {
            /// <summary>
            /// 解除全局状态事件绑定
            /// </summary>
            /// <param name="event" type="type">要解除的事件类型</param>
            /// <param name="fnCallback" type="type">要解除的回调方法，不传则解除所有已绑定的回调</param>

            if (SoBiz._eventHandlers[event]) {
                if (fnCallback) {
                    for (var h in SoBiz._eventHandlers.event) {
                        if (SoBiz._eventHandlers.event[h] === fnCallback) {
                            SoBiz._eventHandlers.event.splice(h, 1);
                            break;
                        }
                    }
                }
                else {
                    SoBiz._eventHandlers[event] = [];
                    delete SoBiz._eventHandlers[event];
                }
            }
            return SoBiz;
        },

        trigger: function (event, data) {
            /// <summary>
            /// 发出全局事件通知
            /// </summary>
            /// <param name="event" type="type">事件类型</param>
            /// <param name="data" type="type">事件参数</param>
            if (SoBiz._eventHandlers[event]) {
                SoBiz._eventHandlers[event].forEach(function (h) {
                    try {
                        h.call(SoBiz, data);
                    }
                    catch (ex) {
                        SoBiz.Debug(window.location.href, "ExceptionOnEvent:" + event);
                    }
                });
            }
            return SoBiz;
        },

        wsconnector: function () {
            var msgCallbacks = [];
            var ws;
            var clntid;
            var svr = (RES.IMSSL ? "wss://" : "ws://") + RES.IMSvr + "/ws";
            var msgCache = [];
            SoBiz.SessionID(function (c) {
                clntid = c;
                ws = new WebSocket(svr + "?clntid=" + clntid);
                ws.onclose = function (ev) {
                };
                ws.onerror = function (er) {
                    console.log("wsconnector err", er);
                };
                ws.onopen = function (ep) {
                    console.log("wsconnector ready", ep);
                    //检查是否存在待发送的消息
                };
                ws.onmessage = function (m) {
                    msgCallbacks.forEach(function (f) {
                        f.call(this, JSON.parse(m.data));
                    });
                };
            });

            this.onmessage = function (fnCallback) {
                msgCallbacks.push(fnCallback);
                return this;
            };
            this.offmessage = function (fnCallback) {
                msgCallbacks.removeOn(fnCallback);
                return this;
            };
            this.sendmessage = function (msg) {
                if (ws.readyState == 1) {
                    //已连接，直接发送
                    ws.send(msg);
                }
                else {
                    //TODO:重新连接，缓存待发送消息
                    msgCache.push(msg);
                    ws = new WebSocket(svr + "?clntid=" + clntid);
                }
                return this;
            };
            this.dispose = function () {
                ws.close();
                ws = null;
                this.ready = false;
                return null;
            };
            this.ready = true;
            return this;
        },

        httpconnector: function () {
            var clntid;
            var msgCallbacks = [];
            var lstn = function () {
                if (msgCallbacks.length > 0) {
                    SoBiz.SessionID(function (clnt){
                        this.clntid = clnt;
                        $.getJSON((RES.IMSSL ? "https://" : "http://") + RES.IMSvr + "/im" + "?clntid=" + clntid, function (rtn) {
                            //TODO:处理拉取到的消息,间隔轮询
                            setTimeout(this.lstn, 1000);
                        });
                    });
                }
            }.bind(this);

            this.onmessage = function (fnCallback) {
                msgCallbacks.push(fnCallback);
                lstn();
                return this;
            };
            this.dispose = function () {
                this.ready = false;
                return null;
            };
            this.ready = true;
            lstn();
            return this;
        },

        CONNECTOR: {
            ready: false,
            dispose: function () { }
        },

        taskmng: function (reqs, tm) {
            var jobs = [];
            var fnThen = null;
            var ender = null;
            var chker = null;
            var isCompleted = false;
            var timeout = 30000;
            var start = new Date();

            var monit = function () {
                if (new Date() - start > timeout) {
                    clearInterval(chker);
                    jobs = [];
                    return;
                }
                else {
                    for (var i = 0; i < jobs.length; i++) {
                        if (jobs[i].readyState == 4) {
                            clearInterval(chker);
                            jobs = [];
                            isCompleted = true;
                            fnThen && fnThen.call();
                            return;
                        }
                    }
                }

            };

            this.Do = function (job) {
                jobs.push(job);
                if (!chker && !isCompleted) {
                    chker = setInterval(monit, 50);
                }
                return this;
            };

            this.Then = function (fn, tm) {
                if (isCompleted) {
                    fn && fn.call();
                }
                else {
                    fnThen = fn;
                    timeout = tm;
                }

                return this;
            };

            return this;
        },

        Debug: function (src, err) {
            /// <summary>
            /// TODO:记录前端错误以供后期调试分析
            /// </summary>
            /// <param name="src" type="String">请求地址和参数</param>
            /// <param name="err" type="String">错误描述</param>
        },
        CheckAll: function ($e) {
            if (!$e) {
                $e = $("body");
            }
            $e.find("data-checker");
        }
    };

    window.$$ = window.SoBiz;

    Object.freeze(window.SoBiz);
    Object.defineProperty(window, 'SoBiz', {
        writable: false
    });
}

//全局页面基础支持
$(function () {
    //异步页面部件加载
    setTimeout(function () {
        $("body").find(".Tabs").each(function (t) {
            var tab = $(this).children(".active").first();
            if (tab.length == 0) {
                tab = $(this).children("span").first();
            }
            if (tab.length > 0 && $(this).children(".tab-hover").length == 0) {
                var hovr = $("<div class='tab-hover'>").insertAfter(tab);
                hovr.width(tab.outerWidth())
                    .css("left", tab.offset().left - tab.offsetParent().offset().left);
            }
        });

        $('body').find("[content-src]").each(function (e) {
            var cnt = this.getAttribute("content-src");
            var rp = this.getAttribute("replace");
            var refDom = $(this);
            if (!rp) {
                $(this).load(cnt);
            }
            else {
                var refDom = $(this);
                $.ajax({
                    url: cnt,
                    dataType: "html",
                    success: function (rtn) {
                        $(rtn).insertBefore(refDom);
                        refDom.remove();
                    }
                });
            }
        });
    }, 200);

    $("body").delegate(".Tabs>span", "mouseenter", function (ev) {
        var tab = $(this);
        var hovr = tab.siblings(".tab-hover");
        if (hovr.length == 0) {
            hovr = $("<div class='tab-hover'>").insertAfter(tab);
        }
        hovr.width(tab.outerWidth())
            .css("left", tab.offset().left - tab.offsetParent().offset().left);
    }).on("mouseleave", ".Tabs", function (ev) {
        var hovr = $(this).children(".tab-hover");
        var tab = $(this).children(".active");

        if (hovr.length == 0) {
            hovr = $("<div class='tab-hover'>").appendTo(this);
        }
        if (tab.length > 0) {
            hovr.width(tab.outerWidth())
                .css("left", tab.offset().left - tab.offsetParent().offset().left);
        }
    });

    $("body").on("DOMSubtreeModified", function (e) {
        $("body").find("._checkon").each(function () {
            var elm = $(this);
            if (!elm.data("checker")) {
                elm.data("checker", new LiberUI.InputChecker(elm));
            }
        });
    });
    SoBiz.SSOProcess(RES.SSOUrl);
});

function reduceRefer(n, oid) {
    var nn = n.nodeName.toLowerCase();
    if (nn == 'script' || nn == 'link') {
        var refsAttr = n.getAttribute("reference");
        var refs = refsAttr !== null ? refsAttr.replace(/oid/g, ''): 'raw';
        if (refs.trim().length == 0) {
            console.log('try remove');
            document.head.removeChild(n);
        }
        else {
            n.setAttribute("reference", refs);
        }
    }
}

function appendRefer(n, id) {
    var refAttr = n.getAttribute("reference");
    if (!refAttr || refAttr.indexOf(id) == -1) {
        n.setAttribute("reference", refAttr + " " + id);
    }
}

/// <reference path="jquery.js" />
/// <reference path="Liber.Base.js" />
'use strict'

if (!window.LiberUI) {
    window.GetDPI = function () {
        var arrDPI = new Array;
        if (!window.screen.deviceYDPI) {
            var tmpNode = document.createElement("DIV");
            tmpNode.style.cssText = "width:1in;height:1in;position:absolute;left:0px;top:0px;z-index:99;visibility:hidden";
            document.body.appendChild(tmpNode);
            arrDPI[0] = parseInt(tmpNode.offsetWidth);
            arrDPI[1] = parseInt(tmpNode.offsetHeight);
            tmpNode.parentNode.removeChild(tmpNode);
        }
        else {
            arrDPI[0] = window.screen.deviceXDPI;
            arrDPI[1] = window.screen.deviceYDPI;
        }
        return arrDPI;
    };
    window.LiberUI = {};
    var MouseEvent = null;
    var mouseStoper = null;
    LiberUI.IsCheckingMouse = false;
    LiberUI.MouseMoinitor = function (ev) {
        /*捕获鼠标事件待后面使用*/
        MouseEvent = ev || window.event;
        ev && ev.stopPropagation();
    };
    LiberUI.Stopper = function () {
        //MouseEvent = null;
        LiberUI.IsCheckingMouse = false;
        document.removeEventListener("mousemove", LiberUI.MouseMoinitor);
        document.removeEventListener("click", LiberUI.MouseMoinitor);
        window.clearTimeout(mouseStoper);
    };
    LiberUI.TryGetHotElement = function () {
        if (LiberUI.IsCheckingMouse == false) {
            document.addEventListener("mousemove", LiberUI.MouseMoinitor);
            document.addEventListener("click", LiberUI.MouseMoinitor);
            LiberUI.IsCheckingMouse = true;

            //停止将要执行的停止动作
            if (mouseStoper != null) {
                window.clearTimeout(mouseStoper);
            }
            mouseStoper = setTimeout(LiberUI.Stopper, 5000);  //5秒后停止监听,除非此方法被再次调用
            return MouseEvent == null ? null : $(MouseEvent.toElement);
        }
        else {
            //TODO:计算鼠标当前停留的元素,考虑不同浏览器的实现方式
            //停止将要执行的停止动作
            if (mouseStoper != null) {
                window.clearTimeout(mouseStoper);
            }
            mouseStoper = setTimeout(LiberUI.Stopper, 5000);  //5秒后停止监听,除非此方法被再次调用
            return MouseEvent == null ? null : $(MouseEvent.toElement);
        }
    };

    //初始化快速UI支持
    $(function () {
        var tpm = $('<div id="tplPrompt" cntid="prompt" style="display:none"><div class="prompt_success"><div class="p_body"><h4>title</h4><span>message</span></div></div><div class="prompt_info"><div class="p_body"><h4>title</h4><span>message</span></div></div><div class="prompt_err"><div class="p_body"><h4>title</h4><span>message</span></div></div><div class="prompt_warn"><div class="p_body"><h4>title</h4><span>message</span></div></div></div>').appendTo("body");

        window.success = function (title, msg, delay, fnCallback) {
            var cnt = $("#tplPrompt>.prompt_success").clone();
            cnt.children(".p_body").children("h4").vl(title);
            cnt.children(".p_body").children("span").vl(msg);
            var p = new LiberUI.Prompt(cnt);
            p.option("Delay", delay);
            p.update();
            if (ObjHelper.IsFunc(fnCallback)) {
                p.on("disposed", fnCallback);
            }
            return p.show();

        };
        window.info = function (title, msg, delay, fnCallback) {
            var cnt = $("#tplPrompt>.prompt_info").clone();
            cnt.children(".p_body").children("h4").vl(title);
            cnt.children(".p_body").children("span").vl(msg);
            var p = new LiberUI.Prompt(cnt);
            p.option("Delay", delay);
            p.update();
            if (ObjHelper.IsFunc(fnCallback)) {
                p.on("disposed", fnCallback);
            }
            return p.show();
        };
        window.warn = function (title, msg, delay, fnCallback) {
            var cnt = $("#tplPrompt>.prompt_warn").clone();
            cnt.children(".p_body").children("h4").vl(title);
            cnt.children(".p_body").children("span").vl(msg);
            var p = new LiberUI.Prompt(cnt);
            p.option("Delay", delay);
            p.update();
            if (ObjHelper.IsFunc(fnCallback)) {
                p.on("disposed", fnCallback);
            }
            return p.show();
        };
        window.err = function (title, msg, delay, fnCallback) {
            var cnt = $("#tplPrompt>.prompt_err").clone();
            cnt.children(".p_body").children("h4").vl(title);
            cnt.children(".p_body").children("span").vl(msg);
            var p = new LiberUI.Prompt(cnt);
            p.option("Delay", delay);
            p.update();
            if (ObjHelper.IsFunc(fnCallback)) {
                p.on("disposed", fnCallback);
            }
            return p.show();
        };

        //鼠标跟随提示
        var tipFor = new LiberUI.ToolsTip();
        $("body").delegate("[tip]", "mouseenter", function (ev) {
            //tip.text($(this).attr("tip"));
            tipFor.TipFor($(this))
                .Cnt($(this).attr("tip"))
                .Update(ev);
        }).delegate("[tip]", "mouseleave", tipFor.Hide)
          .delegate("[tip]", "mousemove", tipFor.Update);
    });

    LiberUI.Confirm = function (ttl, cnt, fnNext, waiting, fnCancel, nextBtnName, cancelBtnName) {
        /// <summary>
        /// 进行下一步操作前通知用户
        /// </summary>
        /// <param name="ttl" type="String">标题</param>
        /// <param name="cnt" type="Dom or String">通知内容，可以为一个DOM元素或字符串</param>
        /// <param name="fnNext" type="Function">如果用户确认或时间到达时执行的下一步操作</param>
        /// <param name="waiting" type="Numbric">如果>0则在等待N秒后自动放弃</param>
        /// <param name="fnCancel" type="Fnction">如果允许用户取消，则在取消时回调</param>

        var dlg = new LiberUI.Dialoger().option('Width',260);
        dlg.Title(ttl || '请确认')
            .Content(cnt);

        dlg.BtnEnter(nextBtnName || "确认", "", fnNext || function () { fnCancel == null; dlg.dispose(); }, "onrisky");

        if (fnCancel) {
            dlg.option("Closeble", true);
            dlg.BtnEsc(cancelBtnName || "取消", "", function () { dlg.dispose(); fnCancel && fnCancel(); });
        }
        else {
            dlg.option("Closeble", false);
        };

        if (!isNaN(parseInt(waiting)) && waiting > 0) {
            setTimeout(function (fn) {
                var r = dlg.dispose();
                if (r != null) {
                    fn && fn.call(dlg);
                }
            }, waiting * 1000, fnCancel);
        }
        dlg.update();
        dlg.show();
        return dlg;
    };
}

function LController($elm) {
    if (ObjHelper.IsEmpty($elm)) {
        $elm = $("<div>");
    }
    else {
        $elm = $($elm);
        if ($elm.length > 0) {
            $elm = $elm.eq(0);
        }
        else {
            $elm = $("<div>");
        }
    }
    var ins = this;
    //var evHandls = {};
    var opt = { StyleDisable: "disabled" };
    opt.ShowWay = function (elm) {
        elm.show();
    };
    opt.HideWay = function (elm) {
        elm.hide();
    };

    var data = null;
    this.State = {
        disposed: false,
        enabled: true,
        visible: false,
    };
    this.Dom = $elm;

    this.on = function (event, fn) {
        if (event == "focus" || event == "click" || event == "dbclick" || event == "blur") {
            event = "LC" + event;
        }
        this.Dom.on(event, fn);
        return this;
    };

    this.off = function (event, fn) {
        this.Dom.off(event, fn);
        return this;
    };

    this.vl = function (value) {
        if (value === undefined) {
            return data;
        }
        else {
            var ev = jQuery.Event("valueChanging", { Controller: ins, OldValue: data, NewValue: value });
            this.Dom.trigger(ev);
            if (ev.isDefaultPrevented()) {
                return ins;
            }
            ev = jQuery.Event("valueChanged", { Controller: ins, OldValue: data, NewValue: value });
            data = value;

            if (ins.$model) {
                ins.$model.$data = data;
            }

            this.Dom.trigger(ev);
            ev = null;
            return ins;
        }
    };
    this.option = function (name, value) {
        /// <summary>
        /// 获取或设置某个选项的值
        /// </summary>
        /// <param name="name" type="string">选项名</param>
        /// <param name="value" type="object">选项值</param>
        if (!name) {
            return opt;
        }
        else if (value == null || value == undefined) {
            return opt[name];
        }
        else {
            opt[name] = value;
            return ins;
        }
    };
    this.dispose = function () {
        if (this.State && this.State.disposed == true) {
            return null;
        };
        this.State ? this.State.disposed = true : this.State = {};
        var ev = $.Event("disposed", { Controller: ins });
        if (this.Dom) {
            this.Dom.trigger(ev);
            this.Dom.Controller = null;
            this.Dom.remove();
        }

        data = null;
        ins = null;
        ev = null;
        opt = null;
        this.Dom = null;
        this.State = null;
        delete this.Dom;
        return this;
    };
    this.editble = false;

    var onDomClick = function (ev) {
        if (!ins.State.enabled || ins.State.enabled == false) {
            if (ev && ev.stopPropagation) {
                ev.stopPropagation();
            }
            return false;
        }
        if (ev && ev.stopPropagation) {
            ev.stopPropagation();
        }
        var nev = $.Event("LCclick", { Controller: ins });
        ins.Dom.trigger(nev);
        return ins;
    };
    var onDomBlur = function (ev) {
        if (ins.State.enabled == false) {
            return ins;
        }
        if (ev && ev.stopPropagation) {
            ev.stopPropagation();
        }
        var nev = $.Event("LCblur", { Controller: ins });
        ins.Dom.trigger(nev);
        return ins;
    };
    var onDomFocus = function (ev) {
        if (ins.State.enabled == false) {
            return ins;
        }
        if (ev && ev.stopPropagation) {
            ev.stopPropagation();
        }
        var nev = $.Event("LCfocus", { Controller: ins });
        ins.Dom.trigger(nev);
        return ins;
    };

    this.Dom.on("click", onDomClick);  //防止冲突，将Dom的Clic转换为自定义的LCclick事件
    this.Dom.on("blur", onDomBlur);
    this.Dom.on("focus", onDomFocus);
    this.Dom.data("Controller", ins);
    return ins;
};

LController.prototype = {
    "update": function () {
        if (this.State.disposed == false) {
            var ev = jQuery.Event("update", { Controller: this });
            this.Dom.trigger(ev);
        }
        return this;
    },
    "addClass": function (cssClass) {
        this.Dom.addClass(cssClass);
        return this;
    },
    "attr": function (name, value) {
        return this.Dom.attr(name, value);
    },
    "ID": function (newId) {
        return this.Dom.ID(newId);
    },
    "show": function () {
        if ((this.State && this.State.visible) || this.State.enabled == false) {
            return this;
        }

        this.State.visible = true;
        var ev = jQuery.Event("shown", { Controller: this });
        if (this.option("ShowWay")) {
            this.option("ShowWay").call(this, this.Dom);
        }
        else {
            this.Dom.fadeIn();
        }
        this.Dom.trigger(ev);
        return this;
    },
    "hide": function () {
        if (!this.State || !this.State.visible) {
            return this;
        }
        this.State.visible = false;
        var ev = jQuery.Event("hiden", { Controller: this });
        if (this.option("HideWay")) {
            this.option("HideWay").call(this, this.Dom);
        }
        else {
            this.Dom.fadeOut();
        }
        this.Dom.trigger(ev);
        return this;
    },
    "focus": function () {
        var ev = jQuery.Event("LCfocus", { Controller: this });
        this.Dom.trigger(ev);
        return this;
    },
    "disable": function () {
        this.State.enabled = false;
        var ev = jQuery.Event("disabled", { Controller: this });
        this.Dom.trigger(ev).addClass("disabled").attr("disabled", "disabled");
        this.update();
        return this;
    },
    "enable": function () {
        this.State.enabled = true;
        var ev = jQuery.Event("enabled", { Controller: this });
        this.Dom.trigger(ev).removeClass("disabled");
        this.update();
        return this;
    }
};

//#region 文件上传
LiberUI.Uploader = function ($elm) {
    var ins = this;
    LController.call(this, $elm);

    this.option("FileAPI", "/File/Up")
        .option("Open", "user")  //开放模式 open-无控制,user-限已登录用户,biz-需授权
        .option("Overide", false)  //是否覆盖相同的文件
        .option("UploadNow", true)  //实时上传，or等待用户点击提交
        .option("Multiple", false)  //允许多选
        .option("Thumbnail", true)  //对于图片，是否加载缩略图
        .option("FileType", "")  //允许的文件类型
        .option("MaxSize", 100000000)  //最大文件长度100m
        .option("BlockSize", 40960)  //分块大小，默认40k
        .option("Rename", "")  //重命名
        .option("RandomRename", false)  //开启随机重命名
        .option("MinSize", 1024);   //最小文件长度1k
    ins.vl([]);
    var _input = null;
    _input = $("<input type=file>").hide().appendTo("body");

    var onClick = function (ev) {
        _input.val("");
        //_input.click();
        _input.trigger("click");
    };

    //TODO:将筛选直接设为input的accept属性

    var onUpdate = function (ev) {
        if (ins.option("Multiple") == true) {
            $(_input).attr("Multiple", "multiple");
        }
        else {
            $(_input).removeAttr("Multiple");
        }
        if (ins.option("FileType") == "image/*") {
            ins.option("FileType", ".jpg,.jpeg,.png,.bmp");
        }

        $(_input).attr("accept", ins.option("FileType").toLowerCase());
    };

    var onSlcted = function (ev) {
        if (ins.State.enabled == false) {
            return;
        }
        if (this.files.length == 0) {
            return;
        }
        for (var i = 0; i < this.files.length; i++) {
            var f = this.files[i];
            var fileItems = ins.vl();
            /*检测文件类型限制*/
            var fType = f.name.substring(f.name.lastIndexOf('.'), f.name.length).toLowerCase();

            if (ins.option("FileType").length > 0 && ins.option("FileType").indexOf(fType) == -1) {
                err("错误", "文件类型不符合上传条件。允许的文件类型包括：" + ins.option("FileType"));
                return;
            }

            /*检测文件大小限制*/
            if (ins.option("MaxSize") && ins.option("MaxSize") < f.size) {
                err("错误", "文件大小超过最大限制");
                return;
            };

            var itm = {
                name: ins.option("Rename") == "" ? f.name : ins.option("Rename") + fType,
                uploader: ins,
                obj: f,
                process: 0,
                total: f.size,
                completed: -1,
                thumbnail: "",
                token: "",
                err: "",
                IsAborted: false,
                Change: LiberUI.UploaderBase.onChange
            };
            if (ins.option("RandomRename") == true) {
                itm.name = ((Math.random() / 2 + f.size / 2).toString() + new Date().getMilliseconds().toString()).MD5() + fType;
            }

            itm.name = itm.name.replace(/%/g, "").replace(/&/g, "");
            if (f.size > ins.option("MaxSize")) {
                itm.Result = { IsPositive: false, ErrorSrc: "Uploader", ErrorCode: "TooLarge" };
                itm.Change("uploadFail");
                return;
            };

            if (ins.option("Multiple") == false) {
                /*如果是单选模式*/
                fileItems.length > 0 ? fileItems[0] = itm : fileItems.push(itm);
            }
            else {
                fileItems.push(itm);
            }

            itm.Change("itemSlcted");
            if (f.type.match("image") && ins.option("Thumbnail") == true) {
                //开启了图片预览
                if (window.File && window.FileReader && window.FileList && window.Blob) {
                    var reader = new FileReader();
                    reader.onload = LiberUI.UploaderBase.onImageThumbnailLoad;
                    reader.item = itm;
                    reader.readAsDataURL(f);
                }
                else {
                    //如果不支持，另外处理
                    log("浏览器不支持Html5文件API");
                    break;
                }
            }

            if (ins.option("UploadNow") == true) {
                if (f.size > 8388608) {
                    //大于8m的，则根据token校验是否存在
                    LiberUI.UploaderBase.checkInfo(itm);
                }
                else {
                    LiberUI.UploaderBase.uploadItemH5(itm);
                }
            }

        }
    };

    var onItemChange = function (ev) {
        switch (ev.Status) {
            case "fileReading":
                //文件读取中
                break;
            case "fileReadEnd":
                //文件读取完毕
                break;
            case "checkInfoEnd":
                //检查文件信息完毕
                if (!ev.Item.Result && (ins.option("UploadNow") == true || ev.Item.uploadNow == true)) {
                    ev.Item.Change("uploadBegin");
                    LiberUI.UploaderBase.uploadItemH5(ev.Item);
                }
                break;
            case "uploadProcessing":
                //文件上传过程中，显示上传进度
                break;
            case "uploadEnd":
                //上传结束
                console.log(ev);

                break;
            case "uploadFail":
                //上传失败
                break;
            case "imageLoaded":
                //图像预览加载完毕
                if (ev.Item.thumbnail && ins.Dom.is("img")) {
                    ins.Dom.attr("src", ev.Item.thumbnail);
                }
                break;
        }
    };

    this.Upload = function (_itmIndex) {
        var i = parseInt(_itmIndex);
        if (!isNaN(i)) {
            //大于8m的，先检测token再上传
            var itm = ins.vl()[i];
            if (itm.obj.size > 8388608) {
                itm.uploadNow = true;
                LiberUI.UploaderBase.checkInfo(itm);
            }
            else {
                LiberUI.UploaderBase.uploadItemH5(itm);
            }
        }
        else {
            var fileItems = ins.vl();
            for (var i = 0; i < fileItems.length; i++) {
                if (fileItems[i].obj.size > 8388608) {
                    fileItems[i].uploadNow = true;
                    LiberUI.UploaderBase.checkInfo(fileItems[i]);
                }
                else {
                    fileItems[i].Change("uploadBegin");
                    LiberUI.UploaderBase.uploadItemH5(fileItems[i]);
                }

            }
        }
        return this;
    };

    this.Abort = function (_itemIndex) {
        if (parseInt(_itemIndex)) {
            var i = ins.vl()[_itemIndex];
            i.IsAborted = true;
            if (i.handler) {
                i.handler.abort();
                i.handler = null;
            }
        }
        else {
            var fileItems = ins.vl();
            for (var i = 0; i < fileItems.length; i++) {
                fileItems[i].IsAborted = true;
                if (fileItems[i].handler) {
                    fileItems[i].handler.abort();
                    fileItems[i].handler = null;
                }
            }
        }
        return this;
    };

    this.Clear = function (_itemIndex) {
        if (parseInt(_itemIndex)) {
            ins.vl(ins.vl().splice(_itemIndex));
        }
        else {
            ins.vl([]);
        }
        return this;
    };

    _input.on("change", onSlcted);

    this.on("update", onUpdate);
    this.on("click", onClick);
    this.on("change", onItemChange);
    this.on("disabled", function () { _input.attr("disabled", true); });
    this.on("enabled", function () { _input.attr("disabled", false); });
    this.on("valueChanging", function (e) {
        if (e.NewValue == null || e.NewValue.length == 0) {
            var fileItems = ins.vl();
            for (var i = 0; i < fileItems.length; i++) {
                if (fileItems[i].handler && fileItems[i].handler.dispose) {
                    fileItems[i].handler.dispose();
                    fileItems[i].uploader = null;
                    fileItems[i] = null;
                }
            }
        }
    });

    this.constructor = LiberUI.Uploader;
}
LiberUI.Uploader.prototype = LController.prototype;
LiberUI.UploaderBase = {
    Filter: function (_types) {

    },
    onChange: function (ev) {
        //发出当前上传过程事件
        var nev = jQuery.Event("change", { Controller: this.uploader, Item: this, Status: ev });
        this.uploader.Dom.trigger(nev);
    },
    onImageThumbnailLoad: function (ev) {
        this.item.thumbnail = this.result;
        this.onload = LiberUI.UploaderBase.onItemLoad;
        this.item.Change("imageLoaded");
        this.item = null;
    },
    onItemLoad: function (ev) {
        /// <summary>
        /// 读取成功完成
        /// </summary>
        /// <param name="ev" type="type"></param>
        this._item.Change("fileLoad");
        return this;
    },
    onItemLoadEnd: function (ev) {
        /// <summary>
        /// 读取结束（可能失败，也可能成功）
        /// </summary>
        /// <param name="ev" type="type"></param>
        this._item.Change("fileLoadEnd");
        return this;
    },
    onItemLoading: function (ev) {
        /// <summary>
        /// 读取过程中
        /// </summary>
        /// <param name="ev" type="type"></param>
        this._item.Change("fileLoading");
        return this;
    },
    checkInfo: function (itm) {
        var f = itm.obj;
        var md5Token = "";
        var url = itm.uploader.option("FileAPI") + "?mode=getInfo&fileName=" + encodeURIComponent(itm.name);

        //计算md5token作为唯一标识
        try {
            var tmpReader = new FileReader();
            tmpReader.readAsArrayBuffer(f);
            itm.Change("fileReading");
            tmpReader.item = itm;
            tmpReader.onload = function (e) {
                if (!this.item.token) {
                    var bufer = this.result;
                    var head = new Uint16Array(bufer, 0, 10240);
                    var mid = new Uint16Array(bufer, parseInt(bufer.byteLength / 8) * 2, 10240);
                    var tail = new Uint16Array(bufer, parseInt(bufer.byteLength / 4) * 2 - 10240, 10240);

                    md5Token = (String.fromCharCode.apply(null, head) + String.fromCharCode.apply(null, mid) + String.fromCharCode.apply(null, tail) + bufer.byteLength.toString()).MD5();

                    this.item.token = md5Token;
                    this.item.dataObj = bufer;
                    url += "&token=" + md5Token;
                    this.item.Change("checkInfo");
                    var checker = new XMLHttpRequest();
                    checker.open("get", url);
                    checker.onreadystatechange = LiberUI.UploaderBase.onCheckInfoEnd;
                    checker.item = this.item;
                    checker.send();
                }
            };
        }
        catch (ex) {
            md5Token = "";
            url += "&token=" + md5Token;
            itm.Change("checkInfo");
            var checker = new XMLHttpRequest();
            checker.open("get", url);
            checker.onreadystatechange = LiberUI.UploaderBase.onCheckInfoEnd;
            checker.item = itm;
            checker.send();
        }
    },
    onCheckInfoEnd: function (ev) {
        /// <summary>
        /// 检查服务端是否存在指定文件或片段
        /// </summary>
        /// <param name="ev" type="type"></param>
        if (this.readyState == 4 && this.status == 200 && this.response) {
            this.onreadystatechange = null;
            var rtn = this.response.toJSON();
            if (rtn.IsPositive) {
                if (rtn.Data.completed < rtn.Data.length) {
                    //获取到已经上传的进度，准备从已完成的部分开始继续上传
                    this.item.completed = rtn.Data.completed;
                }
                else {
                    //已经传完了
                    this.item.Result = rtn.Data;
                    this.item.completed = rtn.Data.completed;
                    this.item.Change("uploadEnd");
                }
            }
            else {
                //没有查到进度，从头开始传
                this.item.completed = 0;
            }
            this.item.Change("checkInfoEnd");
        }
    },
    uploadItemH5: function (itm) {
        if (itm.handler) {
            itm.Change("uploadEnd");
            return;
        };
        if (itm.total <= itm.completed) {
            //已经传完了
            itm.Change("uploadEnd");
            return;
        };
        if (itm.obj.size > 8388608 || itm.completed > 0) {
            //大于8m的，分段读取，分段上传
            var url = itm.uploader.option("FileAPI") + "?mode=append&fileName=" + encodeURIComponent(itm.name);
            url += "&token=" + itm.token;
            url += "&open=" + (itm.uploader ? itm.uploader.option("Open") : "user");
            url += "&overide=" + (itm.uploader ? itm.uploader.option("Overide") : false);
            itm.handler = new XMLHttpRequest();
            itm.handler.withCredentials = true;
            itm.handler.item = itm;
            itm.handler.onreadystatechange = LiberUI.UploaderBase.appendEnd;  //上传完成继续下一次追加上传
            var blockSize = parseInt(itm.uploader.option("BlockSize"));
            var fd = new FormData();
            var ln = Math.min(blockSize, itm.total - itm.completed);  //分块上传
            var data = itm.obj.slice(itm.completed, itm.completed + ln);  //自上次完成位置读取分段数据

            fd.append("file", data, itm.name);
            fd.append("token", itm.token);
            itm.handler.open("post", url + "&start=" + itm.completed + "&total=" + itm.total);
            //itm.handler.setRequestHeader("X-Liber-UTkn", $.Cookie("uTicket"));
            itm.handler.send(fd);
        }
        else if (itm.obj.size > 512000) {
            //大于500k的，优先采用流式上传
            itm.token = "";
            if (window.FileReader) {
                //H5环境，使用FileReader上传
                var reader = new FileReader();
                reader.item = itm;
                reader.onload = LiberUI.UploaderBase.fileReadEnd;
                reader.readAsArrayBuffer(itm.obj);
            }
            else {
                //否则直接以文件方式上传
                var url = itm.uploader.option("FileAPI") + "?mode=upload&fileName=" + encodeURIComponent(itm.name);
                url += "&open=" + (itm.uploader ? itm.uploader.option("Open") : "user");
                url += "&overide=" + (itm.uploader ? itm.uploader.option("Overide") : false);
                itm.handler = new XMLHttpRequest();
                itm.handler.item = itm;
                itm.handler.withCredentials = true;
                itm.handler.onreadystatechange = LiberUI.UploaderBase.appendEnd;
                var fd = new FormData();
                fd.append("file", itm.obj, itm.name);
                itm.handler.open("post", url + "&start=" + itm.completed + "&total=" + itm.total);
                //itm.handler.setRequestHeader("X-Liber-UTkn", $.Cookie("uTicket"));
                itm.handler.send(fd);
            }
        }
        else {
            //否则直接以文件方式上传
            var url = itm.uploader.option("FileAPI") + "?mode=upload&fileName=" + encodeURIComponent(itm.name);
            //url += "&token=" + itm.token;
            url += "&open=" + (itm.uploader ? itm.uploader.option("Open") : "user");
            url += "&overide=" + (itm.uploader ? itm.uploader.option("Overide") : false);
            itm.handler = new XMLHttpRequest();
            itm.handler.withCredentials = true;
            itm.handler.item = itm;

            itm.handler.onreadystatechange = LiberUI.UploaderBase.appendEnd;

            var fd = new FormData();
            fd.append("file", itm.obj, itm.name);
            itm.handler.open("post", url + "&start=" + itm.completed + "&total=" + itm.total);
            //itm.handler.setRequestHeader("X-Liber-UTkn", $.Cookie("uTicket"));
            itm.handler.send(fd);
        }
    },
    appendEnd: function (ev) {
        if (this.readyState == 4 && this.response.length > 0) {
            if (this.item.IsAborted) {
                itm.Change("uploadCanceled");
                return;
            }
            var rtn = this.response.toJSON();
            var itm = this.item;
            if (rtn.IsPositive) {
                itm.completed = rtn.Data.completed;
                if (itm.completed < this.item.total) {
                    itm.Change("uploadProcessing");
                    var url = itm.uploader.option("FileAPI") + "?mode=append&fileName=" + encodeURIComponent(itm.name);
                    url += "&token=" + itm.token;
                    url += "&open=" + (itm.uploader ? itm.uploader.option("Open") : "user");
                    url += "&overide=" + (itm.uploader ? itm.uploader.option("Overide") : false);
                    itm.handler = new XMLHttpRequest();
                    itm.handler.withCredentials = true;
                    itm.handler.onreadystatechange = LiberUI.UploaderBase.appendEnd;
                    itm.handler.item = itm;

                    var fd = new FormData();
                    var blockSize = parseInt(itm.uploader.option("BlockSize"));
                    var ln = Math.min(blockSize, itm.total - itm.completed);
                    var data = itm.obj.slice(itm.completed, itm.completed + ln);  //自上次完成位置读取分段数据

                    fd.append("file", data);
                    fd.append("token", itm.token);
                    itm.handler.open("post", url + "&start=" + itm.completed + "&total=" + itm.total);
                    itm.handler.send(fd);
                }
                else {
                    itm.handler = null;
                    itm.Result = rtn.Data;
                    itm.Change("uploadEnd");
                }
            }
            else {
                itm.Result = rtn;
                itm.Change("uploadFail");
            }
        }
    },
    fileReadEnd: function (ev) {
        var itm = this.item;
        if (!itm.handler) {
            var url = itm.uploader.option("FileAPI") + "?mode=upload&fileName=" + encodeURIComponent(itm.name);
            url += "&token=" + itm.token;
            url += "&open=" + (itm.uploader ? itm.uploader.option("Open") : "user");
            url += "&overide=" + (itm.uploader ? itm.uploader.option("Overide") : false);
            itm.handler = new XMLHttpRequest();
            itm.handler.withCredentials = true;
            itm.handler.item = itm;
            itm.handler.upload.item = itm;
            itm.handler.upload.onprogress = LiberUI.UploaderBase.fileUploading;
            itm.handler.onreadystatechange = LiberUI.UploaderBase.fileUploadEnd;
            itm.handler.open("post", url);
            //itm.handler.setRequestHeader("X-Liber-UTkn", $.Cookie("uTicket").md4());
            itm.handler.send(this.result);
            itm.Change("fileReadEnd");
        }

    },
    fileUploading: function (ev) {
        var itm = this.item;
        itm.completed = ev.loaded;
        itm.Change("uploadProcessing");
    },
    fileUploadEnd: function (ev) {
        if (this.readyState == 4 && this.response.length > 0) {
            var rtn = this.response.toJSON();
            var itm = this.item;
            if (rtn.IsPositive) {
                itm.Result = rtn.Data;
                itm.Change("uploadEnd");
            }
            else {
                itm.Result = rtn;
                itm.Change("uploadFail");
            }
            this.item = null;
            this.upload.item = null;
        }
    }
}
//#endregion

//#region 提示框
LiberUI.Prompt = function ($elm) {
    var ins = this;
    var closer = null;
    //var mask = null;
    LController.call(this, $elm);

    this.option("Delay", 3);

    var onUpdate = function () {
        var dly = ins.option("Delay");
        if (!dly) {
            dly = 3;
        }
        closer = setTimeout(function () { ins.Dom.removeClass("prompt_active").addClass("prompt_dispose"); setTimeout(function () { ins.dispose(); }, 1000) }, (dly - 1) * 1000);
    };

    var onShow = function () {
        ins.Dom.appendTo("body");
        LayoutHelper.Layout2Wnd(ins.Dom, "AllCenter", null);
        ins.Dom.addClass("prompt_active");
    };

    var onDispose = function () {
        clearTimeout(closer);
        ins.Dom.remove();
    };

    this.on("shown", onShow);
    this.on("disposed", onDispose);
    this.on("update", onUpdate);
    this.constructor = LiberUI.Prompt;
}
LiberUI.Prompt.prototype = LController.prototype;
//#endregion

//#region 对话框
LiberUI.Dialoger = function ($elm) {
    /// <summary>
    /// 对话框基础组件
    /// </summary>
    /// <param name="$elm" type="type"></param>
    /// <returns type="LiberUI.Dialoger"></returns>
    var ins = this;
    var btns = [];
    var fnOnEsc = null;
    var msk = null;
    var phost = null;
    var bodyElm = null;
    var headElm = null;
    var bottomElm = null;
    LController.call(this, $elm);
    ins.Dom.appendTo("body").hide();
    ins.option("MainStyle", "Normal")  //基础样式，取决于对话框的用途性质（Warning危险性操作，Normal一般性操作，Info信息告知）
        .option("Mode", "Box")  //"Flat"为扁平化模式,"Box"为默认模式
        .option("Keybord", true)
        .option("Width",0)
        .option("Closeble", true);  //是否允许用户直接关闭对话框，并触发取消按钮的事件

    this.Dom.addClass("Dialoger");
    if (this.Dom.children().length == 0) {
        headElm = $("<div class='dlg_head'><h4 style='display:none'></h4><i class='dlg_closer'></i></div>").appendTo(ins.Dom);
        bodyElm = $("<div class='dlg_body'>").appendTo(ins.Dom);
        bottomElm = $("<div class='dlg_bottom'>").appendTo(ins.Dom).addClass("dlg_bottom");
    };

    var _onKbEnter = function (ev) {
        if (btns.length > 0 && btns[0].fn && ins.State.enabled == true) {
            var r = btns[0].fn(ins, bottomElm && bottomElm.children(".btnEnter").eq(0));
            ev.stopPropagation();
            if (r == true) {
                ins.hide();
            }
            else if (r == false) {

            }
            else {
                ins.hide();
            }
        };
    };
    var _onKbEsc = function (ev) {
        _closeDlg(ev);
    };
    var _update = function () {
        if (headElm) {
            if (ins.option("Mode") == "Flate") {
                ins.Dom.addClass("Flate");
            }
            else {
                ins.Dom.removeClass("Flate");
            }
            ins.Dom.addClass(ins.option("MainStyle"));

            bottomElm.children(".dlg_btn").remove();

            if (btns.length == 0) {
                bottomElm.hide();
                bodyElm.css("margin-bottom", '1rem');
            }
            else {
                bodyElm.css("margin-bottom", '4rem');
                for (var i = 0; i < btns.length; i++) {
                    var nb = $("<button class='dlg_btn'>").vl(btns[i].title).attr("btnIndex", i);
                    nb.appendTo(bottomElm);
                    nb.addClass(btns[i].class);
                }

            };

            if (!ins.option("Closeble")) {
                headElm.children(".dlg_closer").hide();
            }
            else {
                headElm.children(".dlg_closer").show();
            }
        }
    };
    var _onBtn = function (ev) {
        if (ins.State.enabled == false) {
            return;
        }
        var btn = $(this);
        if (!btn.hasClass("dlg_btn")) {
            btn = btn.parent(".dlg_btn");
            if (btn.length == 0) {
                return;
            }
        }
        var b = parseInt(btn.attr("btnIndex"));
        if (btns[b] && btns[b].fn) {
            var r = btns[b].fn(ins, bottomElm && bottomElm.children("button").eq(b));
            if (r == true) {
                ins.hide();
            }
            else if (r == false) {

            }
            else {
                ins.hide();
            }
        }
    };
    var _onWheel = function (ev) {
        if (ev) {
            ev.stopPropagation();
            return false;
        }
    };
    var _onShow = function () {
        bodyElm.css("width", 200);
        var outerW = bodyElm.outerWidth();
        if (ins.option("Width") > 0) {

            var w = ins.option("Width") < 100 ? document.body.clientWidth * ins.option("Width") / 100 : ins.option("Width");
            bodyElm.css("width", w);
            outerW = w;
        }
        else if (bodyElm && bodyElm.children().length > 0 && bodyElm[0].childNodes[0].clientWidth) {
            bodyElm.css("width", bodyElm[0].childNodes[0].clientWidth + 20);
            outerW = bodyElm[0].offsetWidth;
        }
        ins.Dom.width(outerW);

        msk = $('body').mask(ins.Dom).addClass("DialogMask");

        if (ins.option("Keybord") == true) {
            KeybordHelper.globalOn("enter", _onKbEnter);
            KeybordHelper.globalOn("esc", _onKbEsc);
        }

        ins.Dom.addClass("ani-flade-in-up");
        requestAnimationFrame(function () {
            var i = ins.Dom.find("input");
            if (i.length > 0) {
                i[0].focus();
            }
            else if (btns.length > 0) {
                bottomElm.find("button").eq(0).focus();
            }
            else {

            }
        });

        ins.off("hiden", _onHide).on("hiden", _onHide);
    };
    var _onHide = function () {
        if (phost !== null && phost.length > 0) {
            bodyElm.children().eq(0).appendTo(phost);
        }
        else {
            bodyElm.children().eq(0).hide().appendTo('body');
        }
        ins.Dom.hide().appendTo("body");
        ins.Dom.removeClass("ani-flade-in-up");
        KeybordHelper.globalOff("enter", _onKbEnter);
        KeybordHelper.globalOff("esc", _onKbEsc);
        msk.remove();
        msk = null;

        ins.off("shown", _onShow).on("shown", _onShow);
    };
    var _closeDlg = function (ev) {
        if (ins.option("Closeble") == false) {
            return;
        };

        if (fnOnEsc && ins.State.enabled == true) {
            fnOnEsc(ins, bottomElm && bottomElm.children(".btnEsc").eq(0));
            ev.stopPropagation();
        }
        else if (ins.State.enabled == false) {
            return;
        }
        else {
            ins.hide();
        };

        if (ev && ev.stopPropagation) {
            ev.stopPropagation();
        };
    };
    var _onDispose = function () {
        if (msk) {
            msk.remove();
            msk = null;
        };
        ins.off("shown", _onShow);
        ins.off("hiden", _onHide);
        ins.off("update", _update);
        ins.off("mousewheel", _onWheel);
        ins.off("dispose", _onDispose);
        if (headElm) {
            headElm.undelegate(".dlg_closer", "click", _closeDlg);
            bottomElm.undelegate(".dlg_btn", "click", _onBtn);
        };

        KeybordHelper.globalOff("enter", _onKbEnter);
        KeybordHelper.globalOff("esc", _onKbEsc);
        btns = [];
        fnOnEsc = null;
    };
    var _onDisable = function () {
        //TODO:对话框遮罩式禁用状态
    };
    var _onEnable = function () {
        //TODO:对话框取消禁用遮罩
    };

    this.Title = function (titl) {
        if (headElm) {
            if (titl && titl.length > 0) {
                headElm.children('h4').vl(titl.toString()).show();
            }
            else {
                headElm.hide();
            }
        }

        return this;
    };
    this.Content = function (cnt) {
        if (bodyElm) {
            if (ObjHelper.IsElement(cnt)) {
                bodyElm.vl('');
                phost = $(cnt).parentsUntil('body').eq(0);
                bodyElm.append(cnt);
            }
            else {
                bodyElm.vl(cnt);
            }
        }
        else {
            if (ObjHelper.IsElement(cnt)) {
                ins.Dom.vl('');
                phost = $(cnt).parentsUntil('body').eq(0);
                ins.Dom.append(cnt);
            }
            else {
                ins.Dom.vl(cnt);
            }
        }
        return this;
    };

    this.Resize = function (w, h) {
        if (bodyElm) {
            if (w) {
                bodyElm.css("width", w);
            }
            if (h) {
                bodyElm.css("height", h);
            }

            if (ins.State.visible) {
                ins.Dom.width(bodyElm.outerWidth());
                LayoutHelper.Layout2Parent(ins.Dom, "AllCenter");
            }
        }

        return ins;
    };

    this.BtnEnter = function (btnTitle, btnIcon, btnCallback, btnStyle) {
        if (!btnCallback) {
            btnCallback = _closeDlg;
        }
        btns.splice(0, 0, { title: btnTitle, icon: btnIcon, class: 'btnEnter ' + btnStyle, fn: btnCallback, index: 0 });
        return this;
    };
    this.BtnEsc = function (btnTitle, btnIcon, btnCallback, btnStyle) {
        if (!btnCallback) {
            //如果不指定，默认同关闭按钮处理方式
            btnCallback = _closeDlg;
        }
        else {
            //否则同时取代键盘Esc键功能
            fnOnEsc = btnCallback;
        }

        if (btns.length > 0) {
            btns.splice(1, 0, { title: btnTitle, icon: btnIcon, class: 'btnEsc ' + btnStyle, fn: btnCallback, index: 1 });
        }
        else {
            btns.splice(0, 0, { title: btnTitle, icon: btnIcon, class: 'btnEsc ' + btnStyle, fn: btnCallback, index: 0 });
        }
        return this;
    };
    this.BtnOther = function (btnTitle, btnIcon, btnCallback, btnStyle) {
        btns.splice(btns.length, 0, { title: btnTitle, icon: btnIcon, fn: btnCallback, class: btnStyle, index: btns.length });
        return this;
    };
    this.RemoveBtn = function (btnIndex) {
        btnIndex = parseInt(btnIndex);
        if (!isNaN(btnIndex) && btnIndex < btns.length) {
            btns.splice(btnIndex, 1);
        }
        else {
            btns = [];
        }
        return this;
    };
    this.Close = function (delay) {
        if (!delay) {
            ins.dispose();
        }
        else {
            setTimeout(function () { ins.dispose(); }, delay * 1000);
        }
    };

    this.on("shown", _onShow);
    this.on("hiden", _onHide);
    this.on("update", _update);

    bodyElm && bodyElm[0].addEventListener("mousewheel", _onWheel, { passive: true });
    this.on("disposed", _onDispose);
    this.on("disabled", _onDisable);
    this.on("enabled", _onEnable);
    if (this.option("Closeble") == true) {
        headElm && headElm.on("click", ".dlg_closer", _closeDlg);
    };

    bottomElm && bottomElm.on("click", ".dlg_btn", _onBtn);
    ins.constructor = LiberUI.Dialoger;
    return ins;
};
LiberUI.Dialoger.prototype = LController.prototype;
//#endregion

//#region 自动动态弹出面板
LiberUI.PopPanel = function ($elm) {
    var ins = this;
    var popFor = null;
    var mchecker = null;
    var flag = 0;
    var items = null;
    var slcted = -1;
    var _keyEnterHandler = null;

    LController.call(this, $elm);
    ins.Dom.ID();
    this.option("AutoPopout", true)
        .option("AutoHide", true)
        .option("Position", "down-left") /*位置，默认左下，可选right-up,right-down*/
        .option("Offset", { top: 0, left: 0 })
        .option("AutoWidth", true)
        .option("Exclusive", true)  /*独占模式，会强制关闭其他PopFor*/
        .option("ShowWay", PopPaneBase.ShowWay)
        .option("HideWay", PopPaneBase.HideWay);
    ins.Dom.hide();
    var _checkMouseElm = function (tDom) {
        if (!ins.popFor) {
            ins.hide();
            return;
        }
        clearTimeout(mchecker);
        if (tDom) {
            mchecker = setTimeout(_checkMouseElm, 500);
            return;
        }

        var elm = LiberUI.TryGetHotElement();

        if (elm && (elm[0] == ins.Dom[0] || elm.offsetParent()[0] == ins.Dom[0] || elm.parents('#' + ins.Dom.ID()).length > 0 || elm[0] == ins.popFor[0] || elm.offsetParent()[0] == ins.popFor[0] || elm.parents('#' + ins.popFor.ID()).length > 0)) {
            flag = 0;
            mchecker = setTimeout(_checkMouseElm, 200);
        }
        else if (flag > 1 || !ins.State.visible) {
            ins.hide();
            window.clearTimeout(mchecker);
            mchecker = null;
            flag = 0;
        }
        else {
            /*如果检测到鼠标移动到其他区域，延迟再检查2次来确定是否隐藏*/
            flag += 1;
            mchecker = setTimeout(_checkMouseElm, 200);
        }
    };
    var onShow = function (ev) {
        if (ins.State.enabled == false) {
            return;
        }
        if (ins.option("Exclusive") == true && PopPaneBase.Actived && PopPaneBase.Actived.Dom.ID() !== ins.Dom.ID()) {
            PopPaneBase.Actived.hide();
        };
        PopPaneBase.Actived = ins;

        if (ins.popFor && ins.option("AutoHide") == true) {
            ins.popFor.off("blur", blurView)
                .off('mouseleave', leaveView);
            ins.popFor.on("blur", blurView)
                .on("mouseleave", leaveView);

            ins.Dom.off("mouseleave", leaveElm);
            ins.Dom.off("scroll", scrollOnElm);
            ins.Dom.on("mouseleave", leaveElm);
            ins.Dom.on("scroll", scrollOnElm);
        }

        if (ins._keyEnterHandler && ins._keyEnterHandler instanceof Function) {
            KeybordHelper.globalOn("up", onKeyUp);
            KeybordHelper.globalOn("down", onKeyDown);
            KeybordHelper.globalOn("enter", onKeyEnter);
        };

        ins.off("hiden", onHide).on("hiden", onHide);
        ins.option("ShowWay").call(ins, ins.Dom);
    };
    var onHide = function (ev) {
        if (ins.popFor && ins.option("AutoPopout") == true) {
            ins.popFor.off("mouseenter", showView)
                .off("click", showView)
                .off("focus", showView);

            ins.popFor.on("mouseenter", showView)
                .on("click", showView)
                .on("focus", showView);
        }
        if (ins._keyEnterHandler && ins._keyEnterHandler instanceof Function) {
            KeybordHelper.globalOff("up", onKeyUp);
            KeybordHelper.globalOff("down", onKeyDown);
            KeybordHelper.globalOff("enter", onKeyEnter);
        }

        ins.off("shown", onShow)
            .on("shown", onShow);
    };

    var onKeyUp = function (ev) {
        if (ins.State.visible) {
            ev.preventDefault();
            ev.stopPropagation();
            ev.stopImmediatePropagation();
            if (!ins.items) {
                ins.items = ins.Dom.children();
                ins.slcted = ins.items - 1;
            }
            else {
                $(ins.items[ins.slcted]).removeClass("slcted");
                ins.slcted -= 1;
                if (ins.slcted < 0) {
                    ins.slcted = 0;
                }
            }
            $(ins.items[ins.slcted]).addClass("slcted");
        }
    };

    var onKeyDown = function (ev) {
        if (ins.State.visible) {
            ev.preventDefault();
            ev.stopPropagation();
            ev.stopImmediatePropagation();
            if (!ins.items) {
                ins.items = ins.Dom.children();
                ins.slcted = 0;
            }
            else {
                $(ins.items[ins.slcted]).removeClass("slcted");
                ins.slcted += 1;
                if (ins.slcted >= ins.items.length) {
                    ins.slcted = ins.items.length - 1;
                }
            }
            $(ins.items[ins.slcted]).addClass("slcted");
        }
    };

    var onKeyEnter = function (ev) {
        if (ins.State.visible && ins.slcted != -1) {
            ev.preventDefault();
            ev.stopPropagation();
            ev.stopImmediatePropagation();
            ins._keyEnterHandler && ins._keyEnterHandler.call(ins.items[ins.slcted]);
            ins.hide();
        }
    };

    var showView = function (ev) {
        ev && ev.preventDefault();
        ev && ev.stopPropagation();
        ev && ev.stopImmediatePropagation();
        ins.show();
    };

    var blurView = function (ev) {
        _checkMouseElm();
    };
    var leaveElm = function (ev) {
        _checkMouseElm();
    };
    var leaveView = function (ev) {
        _checkMouseElm();
    };

    var scrollOnElm = function (ev) {
        ev.stopPropagation();
        ev.stopImmediatePropagation();
    };
    var _onDisable = function () {
        ins.popFor && ins.popFor.addClass("disabled");
    };
    var _onEnable = function () {
        ins.popFor && ins.popFor.removeClass("disabled");
    };
    this.PopFor = function ($view) {
        $view = $($view);

        if (ObjHelper.IsElement($view)) {
            if ($view.length > 0) {
                $view = $view.eq(0);
            }
            else {
                ins.popFor = null;
                return ins;
            }

            if (ins.popFor && ins.popFor == $view) {
                return ins;
            };

            ins.popFor = $view;
            if (this.option("AutoPopout") == true) {
                ins.popFor.on("mouseenter", showView)
                    .on("click", showView)
                    .on("focus", showView);
            }
            var style = {
                disable: 'none',
                position: 'absolute',
                zIndex: 100
            }
            ins.Dom.css(style);
            return ins;
        }
        else {
            return ins.popFor;
        };
    };
    this.Keybord = function (fnCallback) {
        /// <summary>
        /// 启用键盘操作
        /// </summary>
        /// <param name="fnCallback" type="type">提供一个回调在用户使用键盘按下Enter键后触发</param>
        ins._keyEnterHandler = fnCallback;
        return this;
    };

    this.on("disabled", _onDisable);
    this.on("enabled", _onEnable);
    this.on("hiden", onHide);
    this.on("shown", onShow);

    ins.constructor = LiberUI.PopPanel;
    return ins;
};
LiberUI.PopPanel.prototype = LController.prototype;
var PopPaneBase = {
    'ShowWay': function ($elm) {
        var v = this.PopFor();
        if (!v) {
            return;
        }
        var p = this.option("Position") || 'down-left';
        var of = this.option("Offset") || { top: -1 };
        v.addClass("active");
        $elm.appendTo("body").show();
        if (this.option("AutoWidth") == true) {
            $elm.css("width", v.outerWidth());
        };

        $elm.css({ height: 'auto', visibility: 'visible' }).removeClass("ani-flade-out-up").addClass("ani-flade-in-up");
        LayoutHelper.PosToBody(v, $elm, p, of);
    },
    'HideWay': function ($elm) {
        var v = this.PopFor();
        if (!v) {
            return;
        }
        $elm.removeClass("ani-flade-in-up").addClass('ani-flade-out-up');
        v.removeClass("active");
    },
    'Actived': null
}
//#endregion

//#region 输入组校验器
LiberUI.InputChecker = function ($elm) {
    var ins = this;
    var regEmail = new RegExp(/^([A-Za-z0-9_\-\.\u4e00-\u9fa5])+\@([A-Za-z0-9_\-\.])+\.([A-Za-z]{2,8})$/);
    var regMphone = new RegExp(/^1[0-9]{10}$/);
    var errTip = $("<span class='err'>");
    LController.call(this, $elm);
    ins.Dom.ID();
    ins.option("OnError", null);
    ins.option("ErrTip", "bottom");
    var reset = function (elm) {
        if (elm.hasClass("error")) {
            elm.removeClass("error");
            elm.siblings("span.err").remove();
        };
    };

    var setErr = function (elm, errType, errInfo) {
        if (elm.hasClass("error")) {
            return;
        }
        elm.addClass("error");
        if (ObjHelper.IsFunc(ins.option("OnError"))) {
            ins.option["OnError"].call(elm, errType, errInfo);
        }
        else {
            var tip = errTip.clone();
            if (ins.option("ErrTip") == "bottom") {
                tip.addClass("input-check-bottom");
            }
            else {
                tip.addClass("input-check");
            }
            tip.text(errInfo);
            tip.insertAfter(elm);
        }
    };

    var onChecking = function (e, ruls) {
        //清除上次的检查结果
        var elm = $(e);
        reset(elm);
        if (!ins.State.enabled) {
            return true;
        }
        var rs = elm.data();
        var v = elm.vl();
        if (rs["required"] && (!ruls || ruls.indexOf("required") > -1) && ObjHelper.IsEmpty(v)) {
            setErr(elm, "required", rs["required"]);
            return false;
        }
        if (rs["email"] && (!ruls || ruls.indexOf("email") > -1) && v.toString().length > 0 && !regEmail.test(v)) {
            setErr(elm, "email", rs["email"]);
            return false;
        }
        if (rs["mphone"] && (!ruls || ruls.indexOf("mphone") > -1) && v.toString().length > 0 && !regMphone.test(v)) {
            setErr(elm, "mphone", rs["mphone"]);
            return false;
        }
        if (rs["maxLength"] && (!ruls || ruls.indexOf("max-length") > -1) && v.toString().length > 0 && v.toString().length > rs["maxLength"]) {
            setErr(elm, "max-length", "输入内容长度不能超过" + rs["maxLength"] + "字符");
            return false;
        }
        if (rs["minLength"] && (!ruls || ruls.indexOf("min-length") > -1) && v.toString().length < rs["minLength"]) {
            setErr(elm, "min-length", "输入内容长度不能少于" + rs["minLength"] + "字符");
            return false;
        }
        return true;
    };

    this.CheckAll = function (ruls) {
        if (!ins.State.enabled) {
            return true;
        }
        var inputs = this.Dom.find("input");
        var r = true;
        inputs.each(function (i) {
            var currentR = onChecking($(this), ruls);
            r = r && currentR;
        });
        return r;
    };

    this.Dom.delegate("input", "blur", null, function () {
        var _this = this;
        /*延迟执行校验方法，解决失焦无法关闭弹窗，
         *避免插入dom元素导致弹窗大小变化，无法点中弹窗按钮
         */
        setTimeout(function () {
            onChecking($(_this));
        }, 200);
    });
    this.Dom.delegate("input", "keyup", null, function () { reset($(this)); });
    this.constructor = LiberUI.InputChecker;
};
LiberUI.InputChecker.prototype = LController.prototype;
//#endgion

//#region 鼠标跟随提示
LiberUI.ToolsTip = function () {
    var ins = this;
    var defTip = $("<div id='Tip-Box'>").insertAfter("body");
    var cusTip = $("<div id='Tip-Wraper'>").insertAfter("body");
    var tip = defTip;
    var tipFor = null;
    var tipHeigth = 0;
    var pos = null;
    var status = 0;
    LController.call(this, null);

    var updateRaw = function (e) {
        if (tipFor) {
            if (!e) {
                e = { pageY: tipHeight, pageX: 0 };
            }

            tip.css({ top: e.pageY - tipHeigth, left: e.pageX + 20 });
        }
        else {
            tip.css({ height: 0, minHeight: 0, padding: 0 });
        }
    };

    this.Cnt = function (str) {
        if (!str || str.length == 0) {
            this.Hide();
        }
        else if (str.indexOf('#') == 0) {
            cusTip[0].innerHTML = '';
            cusTip.append($(str));
            defTip.css({ height: 0, minHeight: 0, padding: 0 });
            tip = cusTip;
        }
        else {
            defTip.text(str);
            cusTip.css({ height: 0, minHeight: 0, padding: 0 });
            defTip.css({ height: 'auto', minHeight: '2rem', padding: '10px' });
            tip = defTip;
        };
        tipHeigth = tip[0].clientHeight + 10;
        return ins;
    };

    this.TipFor = function (toElm) {
        var tid = $(toElm).ID();
        if (tipFor !== null && tid == tipFor.ID()) {
            return ins;
        }
        else {
            status = 1;
            tipFor = $(toElm);
            pos = tipFor.offset();
        }
        return ins;
    };

    this.Hide = function (checked) {
        if (checked || status == 0) {
            tipFor = null;
            status = 0;
            updateRaw();
        }
        else {
            setTimeout(ins.Hide, 100, true);
        }
    };

    this.Update = function (e) {
        window.requestAnimationFrame(function () {
            updateRaw(e);
        });
        return ins;
    };

    ins.constructor = LiberUI.ToolsTip;
    return ins;
}
LiberUI.ToolsTip.prototype = LController.prototype;
//#endregion

//#region 可恢复到初始状态的对象
FixObj = function (jsonObj) {
    let _origin = JSON.clone(jsonObj || {});
    let _self = this;
    JSON.merge(_self, jsonObj || {});
    this.Update = function (newValues) {
        if (!newValues) {
            return _origin;
        }

        JSON.merge(_origin, newValues);
        JSON.merge(_self, newValues);
        return _self;
    };

    this.ToJSON = function () {
        var tmp = JSON.merge({}, _self);
        delete tmp._origin;
        delete tmp.Update;
        delete tmp.ToJSON;

        return JSON.stringify(tmp);
    };
    return this;
}
//#endregion